build: add oxlint

> Closes #1403

Hi there! Project manager for oxlint here. Thought I'd help get you guys set up with oxlint. This basic setup should help you get your feet wet.
This commit is contained in:
Don Isaac 2024-08-29 01:38:52 -04:00 committed by MiniDigger | Martin
parent 2eb5faa18b
commit a4aed39ece
3 changed files with 6191 additions and 8158 deletions

View File

@ -11,11 +11,13 @@
"previewBuild": "nuxt build && nuxt preview",
"lint:eslint": "eslint --ext \".js,.vue,.ts,.html\" --ignore-path .gitignore --fix .",
"lint:prettier": "prettier -w .",
"lint:oxlint": "oxlint --fix",
"lint:typecheck": "nuxt typecheck",
"prepare": "nuxt prepare && cd .. && husky install frontend/.husky"
},
"lint-staged": {
"*.{ts,js,vue,html}": [
"oxlint --fix",
"prettier -c",
"eslint"
]
@ -92,6 +94,7 @@
"husky": "9.1.4",
"lint-staged": "15.2.9",
"nuxt": "3.12.4",
"oxlint": "0.9.1",
"pnpm": "9.7.1",
"prettier": "3.3.3",
"regenerator-runtime": "0.14.1",

File diff suppressed because it is too large Load Diff

View File

@ -2371,7 +2371,7 @@ export interface HttpResponse<D extends unknown, E extends unknown = unknown> ex
error: E;
}
type CancelToken = Symbol | string | number;
type CancelToken = symbol | string | number;
export enum ContentType {
Json = "application/json",
@ -2446,11 +2446,11 @@ export class HttpClient<SecurityDataType = unknown> {
return {
...this.baseApiParams,
...params1,
...(params2 || {}),
...params2,
headers: {
...(this.baseApiParams.headers || {}),
...(params1.headers || {}),
...((params2 && params2.headers) || {}),
...this.baseApiParams.headers,
...params1.headers,
...(params2 && params2.headers),
},
};
}
@ -2499,7 +2499,7 @@ export class HttpClient<SecurityDataType = unknown> {
return this.customFetch(`${baseUrl || this.baseUrl || ""}${path}${queryString ? `?${queryString}` : ""}`, {
...requestParams,
headers: {
...(requestParams.headers || {}),
...requestParams.headers,
...(type && type !== ContentType.FormData ? { "Content-Type": type } : {}),
},
signal: (cancelToken ? this.createAbortSignal(cancelToken) : requestParams.signal) || null,