Skip to content

Commit

Permalink
build(deps-dev): replace standard with neostandard (#319)
Browse files Browse the repository at this point in the history
  • Loading branch information
Fdawgs authored Dec 8, 2024
1 parent 9e7ecc8 commit 8aad120
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 11 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

[![CI](https://github.com/fastify/light-my-request/actions/workflows/ci.yml/badge.svg?branch=master)](https://github.com/fastify/light-my-request/actions/workflows/ci.yml)
[![NPM version](https://img.shields.io/npm/v/light-my-request.svg?style=flat)](https://www.npmjs.com/package/light-my-request)
[![js-standard-style](https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat)](https://standardjs.com/)
[![neostandard javascript style](https://img.shields.io/badge/code_style-neostandard-brightgreen?style=flat)](https://github.com/neostandard/neostandard)

Injects a fake HTTP request/response into a node HTTP server for simulating server logic, writing tests, or debugging.
Does not use a socket connection so can be run against an inactive server (server not in listen mode).
Expand Down
9 changes: 9 additions & 0 deletions eslint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
'use strict'

module.exports = require('neostandard')({
ignores: [
...require('neostandard').resolveIgnoresFromGitignore(),
'test/benchmark.js',
],
ts: true
})
12 changes: 4 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,16 @@
"form-auto-content": "^3.2.1",
"form-data": "^4.0.0",
"formdata-node": "^6.0.3",
"standard": "^17.1.0",
"neostandard": "^0.11.9",
"tinybench": "^3.0.0",
"tsd": "^0.31.0",
"undici": "^7.0.0"
},
"scripts": {
"benchmark": "node benchmark/benchmark.js",
"coverage": "npm run unit -- --cov --coverage-report=html",
"lint": "standard",
"lint": "eslint",
"lint:fix": "eslint --fix",
"test": "npm run lint && npm run test:unit && npm run test:typescript",
"test:typescript": "tsd",
"test:unit": "c8 --100 node --test"
Expand All @@ -49,10 +50,5 @@
"bugs": {
"url": "https://github.com/fastify/light-my-request/issues"
},
"homepage": "https://github.com/fastify/light-my-request/blob/master/README.md",
"standard": {
"ignore": [
"test/benchmark.js"
]
}
"homepage": "https://github.com/fastify/light-my-request/blob/master/README.md"
}
2 changes: 1 addition & 1 deletion types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ declare namespace inject {
body: (body: InjectPayload) => Chain
headers: (headers: http.IncomingHttpHeaders | http.OutgoingHttpHeaders) => Chain
payload: (payload: InjectPayload) => Chain
query: (query: string | { [k: string]: string | string[] } ) => Chain
query: (query: string | { [k: string]: string | string[] }) => Chain
cookies: (query: object) => Chain
end(): Promise<Response>
end(callback: CallbackFunc): void
Expand Down
2 changes: 1 addition & 1 deletion types/index.test-d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ const dispatch: http.RequestListener = function (req, res) {

const expectResponse = function (res: Response | undefined) {
if (!res) {
return;
return
}
expectType<Response>(res)
console.log(res.payload)
Expand Down

0 comments on commit 8aad120

Please sign in to comment.