Skip to content

Commit 72b3377

Browse files
authored
fix: enforce type imports (#1370)
1 parent b0d9e07 commit 72b3377

22 files changed

+288
-2642
lines changed

.eslintignore

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

.eslintrc.js

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

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ es
99
*.log*
1010
.nyc_output/**
1111
coverage/**
12-
**/*.eslintcache
1312
.pnp.*
1413
.yarn/*
1514
!.yarn/patches

.mocharc.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
// biome-ignore lint/suspicious/noRedundantUseStrict: preserve
12
'use strict';
23

34
module.exports = {

.npmignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@ test
33
coverage
44
.istanbul.yml
55
.babelrc
6-
.eslintignore
7-
.eslintrc
6+
biome.json
87
.github
98
yarn.lock
109
.travis.yml

.prettierignore

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

.prettierrc.js

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

biome.json

Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
{
2+
"$schema": "https://biomejs.dev/schemas/1.9.3/schema.json",
3+
"vcs": {
4+
"enabled": false,
5+
"clientKind": "git",
6+
"useIgnoreFile": false
7+
},
8+
"files": {
9+
"ignoreUnknown": false,
10+
"ignore": [
11+
".yarn",
12+
"node_modules",
13+
"coverage",
14+
"lib",
15+
"lib-esm",
16+
"examples"
17+
]
18+
},
19+
"formatter": {
20+
"enabled": true,
21+
"indentStyle": "space"
22+
},
23+
"organizeImports": {
24+
"enabled": true
25+
},
26+
"linter": {
27+
"enabled": true,
28+
"rules": {
29+
"recommended": true,
30+
"suspicious": {
31+
"noConsole": "error"
32+
}
33+
}
34+
},
35+
"javascript": {
36+
"formatter": {
37+
"quoteStyle": "single"
38+
}
39+
},
40+
"overrides": [
41+
{
42+
"include": ["**/package.json"],
43+
"formatter": {
44+
"lineWidth": 1
45+
}
46+
},
47+
{
48+
"include": ["test/**"],
49+
"linter": {
50+
"rules": {
51+
"complexity": {
52+
"noForEach": "off"
53+
},
54+
"suspicious": {
55+
"noImplicitAnyLet": "off",
56+
"noExplicitAny": "off"
57+
}
58+
}
59+
}
60+
},
61+
{
62+
"include": ["src/**"],
63+
"linter": {
64+
"rules": {
65+
"complexity": {
66+
"useOptionalChain": "off"
67+
},
68+
"suspicious": {
69+
"noImplicitAnyLet": "off",
70+
"noExplicitAny": "off"
71+
}
72+
}
73+
}
74+
}
75+
]
76+
}

examples/basic/.eslintcache

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
[{"/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/index.js":"1","/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/App.js":"2","/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/serviceWorker.js":"3","/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/FirestoreProjects.js":"4","/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/RTDBProjects.js":"5","/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/initFirebase.js":"6","/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/NewProject.js":"7","/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/Project.js":"8","/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/fbConfig.js":"9"},{"size":451,"mtime":1655317617829,"results":"10","hashOfConfig":"11"},{"size":531,"mtime":1655317617829,"results":"12","hashOfConfig":"11"},{"size":4812,"mtime":1655317617829,"results":"13","hashOfConfig":"11"},{"size":1551,"mtime":1655317617829,"results":"14","hashOfConfig":"11"},{"size":1514,"mtime":1655318966047,"results":"15","hashOfConfig":"11"},{"size":1197,"mtime":1655317617829,"results":"16","hashOfConfig":"11"},{"size":806,"mtime":1655317617829,"results":"17","hashOfConfig":"11"},{"size":225,"mtime":1655317617829,"results":"18","hashOfConfig":"11"},{"size":324,"mtime":1655317617829,"results":"19","hashOfConfig":"11"},{"filePath":"20","messages":"21","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"15ic4cq",{"filePath":"22","messages":"23","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"24","messages":"25","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"26","messages":"27","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"28","messages":"29","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"30","messages":"31","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"32","messages":"33","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"34","messages":"35","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"36","messages":"37","errorCount":0,"fatalErrorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/index.js",[],"/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/App.js",[],"/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/serviceWorker.js",[],"/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/FirestoreProjects.js",[],"/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/RTDBProjects.js",[],"/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/initFirebase.js",[],"/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/NewProject.js",[],"/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/Project.js",[],"/Users/scott/Dev/Code/cypress-firebase/examples/basic/src/fbConfig.js",[]]

package.json

Lines changed: 7 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@
99
"clean": "rimraf lib lib-esm",
1010
"build": "tsc",
1111
"watch": "yarn build --watch",
12-
"lint": "eslint . --ext .js,.ts",
13-
"lint:fix": "yarn lint --fix",
14-
"format:check": "prettier --check .",
15-
"format": "prettier --write .",
12+
"format": "biome format --write",
13+
"format:check": "biome format",
14+
"lint": "biome lint",
15+
"lint:fix": "biome lint --write",
1616
"test:base": "GCLOUD_PROJECT=test-project NODE_OPTIONS='--import tsx' mocha ./test/unit/**/*.spec.ts",
1717
"test:cov:base": "nyc --reporter=lcov --reporter=html yarn test:base",
1818
"test:watch": "yarn test:base --watch",
@@ -26,6 +26,7 @@
2626
"firebase-admin": "^11.0.0 || ^12.0.0"
2727
},
2828
"devDependencies": {
29+
"@biomejs/biome": "^1.9.3",
2930
"@commitlint/cli": "19.5.0",
3031
"@commitlint/config-conventional": "19.5.0",
3132
"@firebase/rules-unit-testing": "3.0.4",
@@ -36,26 +37,15 @@
3637
"@types/mocha": "10.0.9",
3738
"@types/node": "20.16.11",
3839
"@types/sinon-chai": "4.0.0",
39-
"@typescript-eslint/eslint-plugin": "8.8.1",
40-
"@typescript-eslint/parser": "8.8.1",
4140
"chai": "4.5.0",
4241
"cypress": "13.15.0",
43-
"eslint": "8.57.1",
44-
"eslint-config-airbnb-base": "15.0.0",
45-
"eslint-config-prettier": "9.1.0",
46-
"eslint-plugin-babel": "5.3.1",
47-
"eslint-plugin-import": "2.31.0",
48-
"eslint-plugin-jsdoc": "50.3.1",
49-
"eslint-plugin-jsx-a11y": "6.10.0",
50-
"eslint-plugin-prettier": "5.2.1",
5142
"firebase": "10.14.1",
5243
"firebase-admin": "12.3.0",
5344
"firebase-tools": "13.22.0",
5445
"husky": "9.1.6",
5546
"lint-staged": "15.2.10",
5647
"mocha": "10.7.3",
5748
"nyc": "17.1.0",
58-
"prettier": "3.3.3",
5949
"rimraf": "6.0.1",
6050
"sinon": "15.2.0",
6151
"sinon-chai": "4.0.0",
@@ -94,11 +84,8 @@
9484
"index.d.ts"
9585
],
9686
"lint-staged": {
97-
"*.{json,md,yaml,yml}": [
98-
"prettier --write"
99-
],
100-
"*.{js,ts}": [
101-
"eslint --fix"
87+
"*.{js,ts,json,md,yaml,yml}": [
88+
"biome check --no-errors-on-unmatched --write"
10289
]
10390
},
10491
"size-limit": [

0 commit comments

Comments
 (0)