Socket
Book a DemoInstallSign in
Socket

@ver0/eslint-config

Package Overview
Dependencies
Maintainers
1
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ver0/eslint-config

ESLint configs used in all ver0 projects

Source
npmnpm
Version
1.2.2
Version published
Weekly downloads
60
-65.71%
Maintainers
1
Weekly downloads
 
Created
Source

@ver0/eslint-config

NPM Version NPM Downloads Dependents (via libraries.io), scoped npm package GitHub Actions Workflow Status


🔬 ESLint configs used in all ver0 projects

Installation

yarn add -D @ver0/eslint-config

Usage

ESLint configuration

This configuration implies usage of typescript and prettier by default, even though it is possible to disable respective lint rules -- these packages will be installed anyways.

import { buildConfig } from '@ver0/eslint-config';

/** @typedef {import('eslint').Linter} Linter */

/** @type {Linter.Config[]} */
const cfg = [
	...buildConfig({
		globals: 'node',
		prettier: true,
		typescript: true,
		json: true,
		markdown: true,
		react: false,
		vitest: false,
	}),
	{
		files: ['README.md'],
		language: 'markdown/gfm',
	},
];

export default cfg;

Array returned from buildConfig function is a list of ESLint configurations that should be spreaded into the final configuration.

Globals configuration also controls some configs and plugins. In case globals is set to node - it enables node plugin and node environment.

Prettier configuration

In order to sync configuration of prettier with ESLint, it is recommended to extend the configuration from this package.

import ver0Cfg from '@ver0/eslint-config/.prettierrc.js';

/**
 * @type {import("prettier").Config}
 */
export default {
	...ver0Cfg,
};

.editorconfig with according configuration can also be copied from this repo.

[*]
indent_style = tab
tab_width = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
max_line_length = 120

[*.yml]
indent_style = space
indent_size = 2

Keywords

eslint

FAQs

Package last updated on 16 May 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