Product
Introducing License Enforcement in Socket
Ensure open-source compliance with Socket’s License Enforcement Beta. Set up your License Policy and secure your software!
@economic/eslint-config
Advanced tools
This is a configuration for ESLint, a tool for identifying and reporting on patterns found in ECMAScript/JavaScript code. It extends configurations from popular style guides like Airbnb, employs Prettier for code formatting, and has TypeScript-specific settings in place.
First, install this config as dev dependency:
npm install @economic/eslint-config -D
and this ESLint React configuration:
module.exports = {
extends: ['@economic'],
parserOptions: {
project: './tsconfig.json',
},
// your overrides here
};
if you want ESLint Base configuration (without React rules):
module.exports = {
extends: ['@economic/eslint-config/base'],
parserOptions: {
project: './tsconfig.json',
},
// your overrides here
};
When using scoped modules it is not possible to omit the eslint-config namespace.
You can always override these rules or add your own in your own .eslintrc.js file. Here's an example of how that might look:
module.exports = {
extends: ['@economic'],
rules: {
'no-console': 'warn',
'react/prop-types': 'off',
},
};
This configuration is set up for use with TypeScript. If you don't use TypeScript, you will have to alter your configuration accordingly. Remember: these are just rules that aim to increase code quality and readability. They are not hard and fast rules. Adjust the configuration to your project's requirements and your team's preferences.
FAQs
E-conomic ESLint config
The npm package @economic/eslint-config receives a total of 220 weekly downloads. As such, @economic/eslint-config popularity was classified as not popular.
We found that @economic/eslint-config demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Ensure open-source compliance with Socket’s License Enforcement Beta. Set up your License Policy and secure your software!
Product
We're launching a new set of license analysis and compliance features for analyzing, managing, and complying with licenses across a range of supported languages and ecosystems.
Product
We're excited to introduce Socket Optimize, a powerful CLI command to secure open source dependencies with tested, optimized package overrides.