Skip to content

Commit

Permalink
chore: update to neostandard linting
Browse files Browse the repository at this point in the history
  • Loading branch information
voxpelli committed Sep 13, 2024
1 parent 9d81f9d commit e9129c2
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 21 deletions.
1 change: 0 additions & 1 deletion .eslintignore

This file was deleted.

4 changes: 0 additions & 4 deletions .eslintrc

This file was deleted.

2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Checks that the installed modules fulfill the requirements of `package.json`, bo
[![npm downloads](https://img.shields.io/npm/dm/installed-check-core.svg?style=flat)](https://www.npmjs.com/package/installed-check-core)
[![Module type: ESM](https://img.shields.io/badge/module%20type-esm-brightgreen)](https://github.com/voxpelli/badges-cjs-esm)
[![Types in JS](https://img.shields.io/badge/types_in_js-yes-brightgreen)](https://github.com/voxpelli/types-in-js)
[![js-semistandard-style](https://img.shields.io/badge/code%20style-semistandard-brightgreen.svg)](https://github.com/voxpelli/eslint-config)
[![neostandard javascript style](https://img.shields.io/badge/code_style-neostandard-7fffff?style=flat&labelColor=ff80ff)](https://github.com/neostandard/neostandard)
[![Follow @voxpelli@mastodon.social](https://img.shields.io/mastodon/follow/109247025527949675?domain=https%3A%2F%2Fmastodon.social&style=social)](https://mastodon.social/@voxpelli)

Exists as a CLI as well: [installed-check](https://www.npmjs.com/package/installed-check)
Expand Down
5 changes: 5 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import { voxpelli } from '@voxpelli/eslint-config';

export default voxpelli({
ignores: ['test/fixtures/jsdoc-in-type-declaration/*'],
});
17 changes: 4 additions & 13 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@
"build:0": "run-s clean",
"build:1-declaration": "tsc -p declaration.tsconfig.json",
"build": "run-s build:*",
"check:installed-check": "installed-check",
"check:installed-check": "installed-check -i @voxpelli/eslint-config -i eslint",
"check:knip": "knip",
"check:lint": "eslint --report-unused-disable-directives .",
"check:lint": "eslint",
"check:tsc": "tsc",
"check:type-coverage": "type-coverage --detail --strict --at-least 99 --ignore-files 'test/*'",
"check": "run-s clean && run-p check:*",
Expand Down Expand Up @@ -59,22 +59,13 @@
"@types/node": "^18.19.29",
"@types/picomatch": "^2.3.3",
"@types/semver": "^7.5.8",
"@voxpelli/eslint-config": "^19.0.0",
"@voxpelli/eslint-config": "^21.0.0",
"@voxpelli/tsconfig": "^12.0.1",
"c8": "^9.1.0",
"chai": "^4.4.1",
"chai-as-promised": "^7.1.1",
"desm": "^1.3.1",
"eslint": "^8.57.0",
"eslint-plugin-es-x": "^7.6.0",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jsdoc": "^46.10.1",
"eslint-plugin-mocha": "^10.4.1",
"eslint-plugin-n": "^16.6.2",
"eslint-plugin-promise": "^6.1.1",
"eslint-plugin-security": "^1.7.1",
"eslint-plugin-sort-destructure-keys": "^1.5.0",
"eslint-plugin-unicorn": "^48.0.1",
"eslint": "^9.10.0",
"expect-type": "^0.19.0",
"husky": "^9.0.11",
"installed-check": "^9.1.2",
Expand Down
1 change: 1 addition & 0 deletions test/installed-check-fix.spec.js
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// eslint-disable-next-line n/no-unsupported-features/node-builtins
import { cp } from 'node:fs/promises';

import chai from 'chai';
Expand Down
5 changes: 3 additions & 2 deletions test/package.test-d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,8 @@ expectTypeOf({} as ListInstalledNormalizedPackageJson).toMatchTypeOf<NormalizedP

expectTypeOf({}).toMatchTypeOf<PackageJsonLike>();
expectTypeOf({} as object).toMatchTypeOf<PackageJsonLike>();
expectTypeOf({} as Record<string,any>).toMatchTypeOf<PackageJsonLike>();
expectTypeOf({} as Record<string,unknown>).toMatchTypeOf<PackageJsonLike>();
expectTypeOf({} as Record<string, any>).toMatchTypeOf<PackageJsonLike>();
expectTypeOf({} as Record<string, unknown>).toMatchTypeOf<PackageJsonLike>();

// @ts-expect-error
expectTypeOf({ name: true }).toMatchTypeOf<PackageJsonLike>;
Expand All @@ -29,4 +29,5 @@ expectTypeOf(new Date()).toMatchTypeOf<PackageJsonLike>;
// @ts-expect-error
expectTypeOf([]).toMatchTypeOf<PackageJsonLike>;
// @ts-expect-error
// eslint-disable-next-line unicorn/no-null
expectTypeOf(null).toMatchTypeOf<PackageJsonLike>;

0 comments on commit e9129c2

Please sign in to comment.