🚀 Socket Launch Week 🚀 Day 3: Socket Acquires Coana.Learn More
Socket
Sign inDemoInstall
Socket

@inrupt/eslint-config-lib

Package Overview
Dependencies
Maintainers
0
Versions
59
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@inrupt/eslint-config-lib

Shared eslint config for Typescript Libraries used at @inrupt

3.2.6
latest
Source
npm
Version published
Weekly downloads
2.6K
-6.61%
Maintainers
0
Weekly downloads
 
Created
Source

eslint-config-inrupt-lib

Eslint and prettier configs

Installation

  • npm install --save-dev @inrupt/eslint-config-lib @rushstack/eslint-patch

Setup (Quick start)

Create a .eslintrc.js in the the root of your project with the following contents:

require("@rushstack/eslint-patch/modern-module-resolution");

module.exports = {
  extends: ["@inrupt/eslint-config-lib"],
  parserOptions: {
    project: "./tsconfig.eslint.json",
  },
  rules: {},
};

The file tsconfig.eslint.json is your typescript configuration with the e2e tests, unit tests and examples included, e.g.,

{
  "extends": "./tsconfig.json",
  "include": ["src/**/*.ts", "e2e/**/*.ts", "examples/**/*.ts", "*.md"],
  "exclude": ["**/node_modules", "**/dist/**"]
}

Migrating to this configuration:

  • Add extends: ['@inrupt/eslint-config-lib'] to your .eslintrc.js file.
  • Add the following line to the top of the .eslintrc.js file:
require("@rushstack/eslint-patch/modern-module-resolution");

Rules

Exhaustive documentation forthcoming. For now, the general principles are:

  • Load inrupt-base, which loads recommended configs for common libraries: eslint, jest, typescript, and prettier
  • Do very little else- as few custom rules or overrides as possible.
  • Some rules are updated to work with nextjs.

Keywords

eslint

FAQs

Package last updated on 20 Mar 2025

Did you know?

Socket

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