Skip to content

Commit cccd58f

Browse files
authored
chore: migrate to neostandard (#462)
Signed-off-by: Aras Abbasi <[email protected]>
1 parent ab1e63d commit cccd58f

File tree

5 files changed

+15
-30
lines changed

5 files changed

+15
-30
lines changed

eslint.config.js

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
'use strict'
2+
3+
module.exports = require('neostandard')({
4+
noJsx: true,
5+
ts: true,
6+
})

package.json

Lines changed: 5 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,8 @@
77
"types": "types/index.d.ts",
88
"scripts": {
99
"coverage": "npm run test:unit -- --coverage-report=html",
10-
"lint": "npm run lint:javascript && npm run lint:typescript",
11-
"lint:javascript": "standard | snazzy",
12-
"lint:fix": "standard --fix && npm run lint:typescript -- --fix",
13-
"lint:typescript": "eslint -c .eslintrc.json types/**/*.d.ts types/**/*.test-d.ts",
10+
"lint": "eslint",
11+
"lint:fix": "eslint --fix",
1412
"test": "npm run test:unit && npm run test:typescript",
1513
"test:typescript": "tsd",
1614
"test:unit": "tap",
@@ -42,29 +40,20 @@
4240
"@fastify/compress": "^8.0.0-pre.fv5.1",
4341
"@fastify/pre-commit": "^2.1.0",
4442
"@types/node": "^22.0.0",
45-
"@typescript-eslint/eslint-plugin": "^7.3.1",
46-
"@typescript-eslint/parser": "^7.3.1",
4743
"concat-stream": "^2.0.0",
44+
"eslint": "^9.9.0",
4845
"fastify": "^5.0.0-alpha.3",
4946
"handlebars": "^4.7.8",
47+
"neostandard": "^0.11.3",
5048
"pino": "^9.1.0",
5149
"proxyquire": "^2.1.3",
5250
"simple-get": "^4.0.1",
53-
"snazzy": "^9.0.0",
54-
"standard": "^17.1.0",
5551
"tap": "^18.7.1",
56-
"tsd": "^0.31.0",
57-
"typescript": "^5.4.3"
52+
"tsd": "^0.31.0"
5853
},
5954
"tsd": {
6055
"directory": "test/types"
6156
},
62-
"eslintConfig": {
63-
"rules": {
64-
"no-unused-vars": "off",
65-
"@typescript-eslint/no-unused-vars": "error"
66-
}
67-
},
6857
"publishConfig": {
6958
"access": "public"
7059
}

tsconfig.eslint.json

Lines changed: 0 additions & 10 deletions
This file was deleted.

types/index.d.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ declare module 'fastify' {
1616
}
1717
}
1818

19-
type FastifyStaticPlugin = FastifyPluginAsync<NonNullable<fastifyStatic.FastifyStaticOptions>>;
19+
type FastifyStaticPlugin = FastifyPluginAsync<NonNullable<fastifyStatic.FastifyStaticOptions>>
2020

2121
declare namespace fastifyStatic {
2222
export interface SetHeadersResponse {
@@ -119,6 +119,6 @@ declare namespace fastifyStatic {
119119
export { fastifyStatic as default }
120120
}
121121

122-
declare function fastifyStatic(...params: Parameters<FastifyStaticPlugin>): ReturnType<FastifyStaticPlugin>;
122+
declare function fastifyStatic (...params: Parameters<FastifyStaticPlugin>): ReturnType<FastifyStaticPlugin>
123123

124-
export = fastifyStatic;
124+
export = fastifyStatic

types/index.test-d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import fastifyStatic, {
88
fastifyStatic as fastifyStaticNamed
99
} from '..'
1010

11-
import fastifyStaticCjsImport = require('..');
11+
import fastifyStaticCjsImport = require('..')
1212
const fastifyStaticCjs = require('..')
1313

1414
const app: FastifyInstance = fastify()

0 commit comments

Comments
 (0)