Shared Eslint config for my projects
yarn add -DE @devshareacademy/eslint-config
Note: In order to use the package, you will need to have the peer dependencies that are listed installed in your project. You can add these dependencies by running the following command:
yarn add -D -E eslint @typescript-eslint/eslint-plugin @typescript-eslint/parser eslint-config-prettier eslint-plugin-prettier prettier
You can install this package from the GitHub NPM Package Repository. In order to do this, you must first authenticate with GitHub packages. You can read more about this process here: GitHub - Installing A GitHub Package.
yarn config set @lookio:registry https://npm.pkg.github.com/
echo "//npm.pkg.github.com/:_authToken=<github_personal_access_token>" > .npmrc
yarn add -DE @devshareacademy/eslint-config
.eslintrc
{
"root": true,
"extends": "@devshareacademy/eslint-config",
"parserOptions": {
"project": "./tsconfig.json"
},
"rules": {}
}
# Authenticate with NPM Package Registry
npm login
# Run publish script
yarn publish:npm
yarn publish:github
- @devshareacademy/eslint-config: eslint-config
- @devshareacademy/tsconfig: tsconfig
- @devshareacademy/prettier-config: prettier-config