standardize-js v0.2.9
standardize-js
standardize-js is a tool to help you set-up linting through eslint and prettier on any javascript project. It also creates a pre-commit hook to ensure that every file committed is correctly formatted.
Table of contents
Features
Status | Feature | Issue |
---|---|---|
✔️ | set up a linter for JavaScript and Typescript following a popular style guide like Airbnb Javascript, Google, JQuery... | |
✔️ | set up prettier to work with this style guide | |
✔️ | install the necessary dev dependencies | |
✔️ | provide you with the configuration files you need to create | |
✔️ | write the files to the disk |
How to use it
npx standardize-js
Quick start
If your project do not have yet a package.json
, you should run :
npm init
You should also make sure that your project is tracked using git
. If that's not the case, initialize the repo using:
git init
Then, issue the following commands:
npm i -g standardize-js
cd my/project/root-folder
standardize-js
Installation procedure
Standardize-js has no dependencies : everything is packed right into it!
Install it globally using:
NPM
npm install -g standardize-js
Yarn
yarn global add standardize-js
Usage
Warning ! Make sure to be in your root folder before issuing any command. Standardize-js won't break your code but it may install a bunch of unnecessary dependencies and files.
You should then be able to use it by simply typing in the command line:
standardize-js
Just answer the questions and you're all set up!