Skip to content

Commit 1bfd9f5

Browse files
committed
style: update to biomejs
1 parent 852cc2e commit 1bfd9f5

File tree

11 files changed

+1155
-1831
lines changed

11 files changed

+1155
-1831
lines changed

.changeset/config.json

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
{
2-
"$schema": "https://unpkg.com/@changesets/config@2.3.0/schema.json",
3-
"changelog": "@changesets/cli/changelog",
4-
"commit": false,
5-
"fixed": [],
6-
"linked": [],
7-
"access": "restricted",
8-
"baseBranch": "main",
9-
"updateInternalDependencies": "patch",
10-
"ignore": []
2+
"$schema": "https://unpkg.com/@changesets/config@2.3.0/schema.json",
3+
"changelog": "@changesets/cli/changelog",
4+
"commit": false,
5+
"fixed": [],
6+
"linked": [],
7+
"access": "restricted",
8+
"baseBranch": "main",
9+
"updateInternalDependencies": "patch",
10+
"ignore": []
1111
}

.editorconfig

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
root = true
2+
3+
# Set up tabs as indent style for a11y reasons
4+
# This will be the default for prettier in >=v3
5+
[*]
6+
indent_style = tab
7+
indent_size = 2
8+
9+
# Yaml does not support tabs
10+
[*.{yml,yaml}]
11+
indent_style = space
12+
indent_size = 2

.eslintignore

Lines changed: 0 additions & 1 deletion
This file was deleted.

.eslintrc.cjs

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

biome.json

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
{
2+
"$schema": "./node_modules/@biomejs/biome/configuration_schema.json",
3+
"vcs": {
4+
"enabled": true,
5+
"clientKind": "git",
6+
"defaultBranch": "main"
7+
},
8+
"json": {
9+
"parser": {
10+
"allowComments": true
11+
}
12+
},
13+
"formatter": {
14+
"enabled": true,
15+
"lineWidth": 80
16+
},
17+
"linter": {
18+
"enabled": true,
19+
"rules": {
20+
"recommended": true,
21+
"complexity": {
22+
"noUselessTernary": "error",
23+
"useDateNow": "error",
24+
"useLiteralKeys": "off"
25+
},
26+
"correctness": {
27+
"noUnusedFunctionParameters": "off",
28+
"noUnusedImports": "error",
29+
"noUnusedVariables": "off"
30+
},
31+
"suspicious": {
32+
"noConsoleLog": "error",
33+
"noEvolvingTypes": "error",
34+
"useErrorMessage": "error"
35+
},
36+
"style": {
37+
"noParameterAssign": "off",
38+
"noUselessElse": "off",
39+
"useConsistentBuiltinInstantiation": "error",
40+
"useFilenamingConvention": {
41+
"level": "error",
42+
"options": {
43+
"requireAscii": true,
44+
"filenameCases": ["kebab-case"]
45+
}
46+
},
47+
"useTemplate": "off",
48+
"useThrowOnlyError": "error"
49+
},
50+
"nursery": {
51+
"noNestedTernary": "warn"
52+
}
53+
}
54+
}
55+
}

package.json

Lines changed: 53 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -1,56 +1,55 @@
11
{
2-
"name": "@labdigital/dataloader-cache-wrapper",
3-
"version": "0.4.0",
4-
"author": "Lab Digital <opensource@labdigital.nl>",
5-
"license": "MIT",
6-
"publishConfig": {
7-
"access": "public"
8-
},
9-
"description": "Wrapper around dataloader to cache the results of the loader",
10-
"keywords": [],
11-
"main": "dist/index.cjs",
12-
"module": "dist/index.js",
13-
"typings": "dist/index.d.ts",
14-
"type": "module",
15-
"exports": {
16-
".": {
17-
"require": "./dist/index.cjs",
18-
"import": "./dist/index.js",
19-
"types": "./dist/index.d.ts"
20-
}
21-
},
22-
"prettier": {
23-
"printWidth": 80,
24-
"semi": false,
25-
"singleQuote": true,
26-
"trailingComma": "es5"
27-
},
28-
"scripts": {
29-
"build": "tsup",
30-
"dev": "tsup --watch",
31-
"publish:ci": "pnpm build && pnpm changeset publish",
32-
"test": "vitest run --coverage",
33-
"test:ci": "vitest run --coverage",
34-
"lint": "eslint src/",
35-
"tsc": "tsc --noEmit"
36-
},
37-
"devDependencies": {
38-
"@changesets/cli": "^2.26.1",
39-
"@types/object-hash": "^3.0.6",
40-
"@vitest/coverage-v8": "^2.1.8",
41-
"dataloader": "^2.2.2",
42-
"eslint": "^8.40.0",
43-
"eslint-plugin-unused-imports": "^2.0.0",
44-
"tsup": "6.7.0",
45-
"typescript": "5.7.2",
46-
"vitest": "^2.1.8"
47-
},
48-
"peerDependencies": {
49-
"dataloader": ">=2.0 <3.0",
50-
"keyv": ">=4.0.0 <6.0.0"
51-
},
52-
"dependencies": {
53-
"object-hash": "^3.0.0"
54-
},
55-
"packageManager": "pnpm@9.4.0"
2+
"name": "@labdigital/dataloader-cache-wrapper",
3+
"version": "0.4.0",
4+
"author": "Lab Digital <opensource@labdigital.nl>",
5+
"license": "MIT",
6+
"publishConfig": {
7+
"access": "public"
8+
},
9+
"description": "Wrapper around dataloader to cache the results of the loader",
10+
"keywords": [],
11+
"main": "dist/index.cjs",
12+
"module": "dist/index.js",
13+
"typings": "dist/index.d.ts",
14+
"type": "module",
15+
"exports": {
16+
".": {
17+
"require": "./dist/index.cjs",
18+
"import": "./dist/index.js",
19+
"types": "./dist/index.d.ts"
20+
}
21+
},
22+
"prettier": {
23+
"printWidth": 80,
24+
"semi": false,
25+
"singleQuote": true,
26+
"trailingComma": "es5"
27+
},
28+
"scripts": {
29+
"build": "tsup",
30+
"dev": "tsup --watch",
31+
"publish:ci": "pnpm build && pnpm changeset publish",
32+
"test": "vitest run --coverage",
33+
"test:ci": "vitest run --coverage",
34+
"lint": "biome check",
35+
"tsc": "tsc --noEmit"
36+
},
37+
"devDependencies": {
38+
"@changesets/cli": "^2.26.1",
39+
"@types/object-hash": "^3.0.6",
40+
"@vitest/coverage-v8": "^2.1.8",
41+
"dataloader": "^2.2.2",
42+
"tsup": "6.7.0",
43+
"typescript": "5.7.2",
44+
"vitest": "^2.1.8"
45+
},
46+
"peerDependencies": {
47+
"dataloader": ">=2.0 <3.0",
48+
"keyv": ">=4.0.0 <6.0.0"
49+
},
50+
"dependencies": {
51+
"@biomejs/biome": "^1.9.4",
52+
"object-hash": "^3.0.0"
53+
},
54+
"packageManager": "pnpm@9.4.0"
5655
}

0 commit comments

Comments
 (0)