Skip to content

Commit eb66d54

Browse files
committed
chore: use @projectwallace/preset-oxlint
1 parent fbefa89 commit eb66d54

File tree

8 files changed

+21
-58
lines changed

8 files changed

+21
-58
lines changed

.oxlintrc.json

Lines changed: 3 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,9 @@
11
{
22
"$schema": "./node_modules/oxlint/configuration_schema.json",
3-
"plugins": [
4-
"import",
5-
"typescript",
6-
"oxc",
7-
"unicorn"
8-
],
3+
"extends": ["@projectwallace/preset-oxlint"],
94
"env": {
105
"node": true,
11-
"browser": true,
12-
"es2024": true
6+
"browser": true
137
},
14-
"categories": {
15-
"perf": "error",
16-
"correctness": "error",
17-
"pedantic": "error"
18-
},
19-
"rules": {
20-
"unicorn/no-null": "error",
21-
"unicorn/prefer-set-has": "off",
22-
"prefer-string-slice": "off",
23-
"prefer-code-point": "off",
24-
"no-lonely-if": "off",
25-
"no-unused-vars": "off",
26-
"no-await-in-loop": "off",
27-
"prefer-query-selector": "off",
28-
"max-dependencies": "off",
29-
"ban-types": "off",
30-
"no-undefined": "off",
31-
"no-useless-undefined": "off",
32-
"max-classes-per-file": "off",
33-
"max-lines-per-function": "off",
34-
"prefer-math-trunc": "off",
35-
"max-lines": "off",
36-
"max-depth": [
37-
"warn",
38-
{
39-
"max": 5
40-
}
41-
],
42-
"explicit-function-return-type": "off",
43-
"no-console": "off",
44-
"no-optional-chaining": "off",
45-
"no-commonjs": "off",
46-
"unambiguous": "off",
47-
"no-default-export": "off",
48-
"no-async-await": "off",
49-
"no-non-null-assertion": "off",
50-
"no-plusplus": "off",
51-
"no-bitwise": "off",
52-
"default-case": "off",
53-
"no-rest-spread-properties": "off",
54-
"require-await": "warn"
55-
}
8+
"rules": {}
569
}

package-lock.json

Lines changed: 12 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@
4747
"devDependencies": {
4848
"@codecov/vite-plugin": "^1.9.1",
4949
"@playwright/test": "^1.56.0",
50+
"@projectwallace/preset-oxlint": "^0.0.6",
5051
"@types/node": "^24.9.2",
5152
"c8": "^10.1.3",
5253
"knip": "^5.66.4",

src/cli/reporters/pretty.test.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
import { test, expect } from '@playwright/test'
2-
import { print_lines as print, PrintLinesDependencies, type StyleTextFn, TextStyle } from './pretty'
2+
import { print_lines as print, PrintLinesDependencies, TextStyle } from './pretty'
33
import { Report } from '../program'
44
import { CoverageResult } from '../../lib'
55
import { CliArguments } from '../arguments'
6-
import { PrettifiedChunk } from '../../lib/prettify'
76

87
// test matrix
98
// ------------------------------
@@ -59,7 +58,6 @@ const min_file_line_coverage_failure = {
5958
}
6059

6160
const show_none = { 'show-uncovered': 'none' } as CliArguments
62-
const show_all = { 'show-uncovered': 'all' } as CliArguments
6361
const show_violations = { 'show-uncovered': 'violations' } as CliArguments
6462

6563
const context_empty = {

src/cli/reporters/tap.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ function meta(data: Record<string | number, string | number>) {
2525
console.log(' ...')
2626
}
2727

28-
export function print({ report, context }: Report, params: CliArguments): void {
28+
export function print({ report, context }: Report, _params: CliArguments): void {
2929
let total_files = context.coverage.coverage_per_stylesheet.length
3030
let total_checks = total_files + 1
3131
let checks_added = 1

src/lib/html-parser.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export class DOMParser {
2828
pos = close + '</style>'.length
2929
}
3030
return {
31-
querySelectorAll(selector: 'style') {
31+
querySelectorAll(_selector: 'style') {
3232
return styles
3333
},
3434
}

src/lib/prettify.test.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
1-
import { test, expect } from '@playwright/test'
2-
import { prettify } from './prettify'
1+
import { test } from '@playwright/test'
32

43
test.skip('simple range at start', () => {})
54
test.skip('simple range at middle', () => {})

src/lib/test/kitchen-sink.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
import { test, expect } from '@playwright/test'
2-
import { calculate_coverage, parse_coverage, type Coverage, type CoverageResult } from '../index.js'
2+
import { calculate_coverage, parse_coverage, type Coverage } from '../index.js'
33
import { generate_coverage } from './generate-coverage.js'
44
import { format } from '@projectwallace/format-css'
55
import * as fs from 'node:fs/promises'

0 commit comments

Comments
 (0)