Skip to content

Informs you of how to camelize words according to the most appropriate set of rules

Notifications You must be signed in to change notification settings

mauriciotasca/camelize

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🐫 camelize

Informs you of how to camelize words according to the most appropriate set of rules approved by the community

Check camelize live, in order to use it

LIVE SITE: https://camelize.netlify.app

Features

  • Shows how the word should be camelized following the community guidelines
  • Camelizes words using lodash.camelcase if no community definition is provided
  • Supports camelization of words with the following delimiters -, _, (space)
  • Description is displayed in HTML, but is also kept in this repo under src/resources

Contributing

In order to add a description to a specific camelization, please execute the following steps

  1. Crete a markdown file inside /resources all lowercase
  2. Add content to the markdown file using the following format
Readonly is a [closed compound word](https://www.grammarly.com/blog/open-and-closed-compound-words/#react-view:~:text=Closed%20Compound%20Words,-Closed) and should _not_ be camelized

Append an object to the existing array inside src/resources/camelArray.ts

  {
    id: ADD_ONE_TO_LAST_INDEX,
    normalized: "myword", // All lowercase and without diacritics (use normalization tool)
    camelCase: "myWord", // The way you think the word should be camelized
    description: descriptions.myword, // path to description markdown file
  },

Add markdown file path to src/resources/index.ts

const myword = raw("./descriptions/myword.md");

This step needs to be followed as raw parses the word and transforms it into a string.

Append the parsed string to the export statement below the latest word

const descriptions = {
  ...
  myword,
}; 

Note

All uncovered words will fall under the template model and {{WORD}} occurrences will be replaced

Sorry ☹️ , No description has been found for **{{WORD}}**, but it should be safe to use it as displayed above,
since it has been generated by lodash's [camelcase](https://www.npmjs.com/package/lodash.camelcase) module.

Please [submit a PR](https://github.com/mauriciotasca/camelize) if you think there should be a different way to camelize **{{WORD}}**.

About

Informs you of how to camelize words according to the most appropriate set of rules

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published