Love to hear any feedback or tips to improve - submit an issue or a fix via a pull request.
Please ensure you're following the below rules before submitting a PR:
Please follow Airbnb's Name Conventions from the style guide.
- Structure
- Follow the existing file structure
- Files
- Should be
lowercase
, with words separated by hyphens (-
) eg.logo-cropped.jpg
- With the exception of Containers and Components, which should be
PascalCase
- eg.RecipeView.js
- Should be
- Directories
- Folder names should be
lowercase,
with words separated by a hyphen (-
) - eg./components/case-studies
- Folder names should be
- Folders and files can be named singlular or plural - do what sounds right
- If there's more than a few files in a directory that are related, group them within their own directory
- eg. if I have 2 components:
/components/RecipeListing.js
and/components/RecipeView.js
, I may choose to create a new directory within components calledrecipes
and put the 2 files within (removingRecipes
). The result would be:/components/recipes/Listing.js
and/components/recipes/View.js
- eg. if I have 2 components:
Please ensure you're code is passing the built in linter.
Please include tests with your code and ensure your code is passing the existing tests.