-
Notifications
You must be signed in to change notification settings - Fork 1
Upgrade Guide
If you are planning on using js-coding-standards, and have previously used WDS-Coding-Standards, please follow this guide to upgrade your setup.
Note, installing js-coding-standards will not just magically work if you have other .editorconfig, JS Hint, or other .eslintrc files in your project tree that point to other configurations.
First, remove WDS-Coding-Standards
You do not need to remove the below packages, for instance, if you are using them globally for other standards, etc. But, removing them will ensure better compatibility with js-coding-standards.
Use npm -g list --depth=0 and see if the below packages are in the list. If it is, it is recommended you remove it from your global install using:
npm -g remove eslintYou do not have to do this step if you want eslint installed globally, just ensure your editors are configured to use the version installed with this package, look for ./node_modules/.bin/eslint.
npm -g remove eslint-config-wordpressThis step is highly recommended.
npm -g remove eslint-plugin-webdevstudiosThis step is highly recommended.
Then install using the steps found here.
If you were previously using WDS-Coding-Standards, you might have your editor setup to use it globally, for instance, in Sublime Text, it looks like:
"disable": false,
"args": [
"--config=/Users/aubreypwd/.composer/vendor/webdevstudios/wds-coding-standards/WebDevStudios/.eslintrc.js",
"--no-eslintrc"
],
"excludes": []You'll want to remove the --config and --no-eslintrc options (or any executable options that point to any global paths):
"disable": false,
"args": [
],
"excludes": []You'll also want to disable and JSHint setup you might have installed too and look at your .editorconfig.
Your editor specifics may vary.