Socket
Socket
Sign inDemoInstall

@edx/eslint-config

Package Overview
Dependencies
262
Maintainers
3
Versions
18
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @edx/eslint-config

ESLint configuration for edX JavaScript code.


Version published
Weekly downloads
8.6K
decreased by-14.19%
Maintainers
3
Created
Weekly downloads
 

Readme

Source

Build Status NPM Version npm_downloads license semantic release

@edx/eslint-config

Installation

If you're using @edx/frontend-build, then you'll get this package for free. Otherwise, you can install it via:

npx install-peerdeps --dev @edx/eslint-config

This will install the package and all of its peer dependencies.

Then, once it's installed, create an .eslintrc.js file in the top-level directory of your project with the following contents:

module.exports = {
  extends: "@edx/eslint-config",
}

Using TypeScript

If @edx/eslint-config detects a tsconfig.json file in the root folder of your project, it will optionally configure ESLint to add support for TypeScript. If a tsconfig.json file exists, the ESLint config will:

  • Extend airbnb-typescript (source).
  • Configure parserOptions.project to point to the tsconfig.json file in the root folder of your project.

airbnb-typescript may only be extended if a tsconfig.json file exists in your project.

If your tsconfig.json file is defined somewhere other than the root folder of your project, you may override the default ESLint configuration by extending airbnb-typescript and including the path to your tsconfig.json file in the parserOptions.project ESLint configuration.

Keywords

FAQs

Last updated on 05 Apr 2024

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc