Skip to content

Commit 7d50d38

Browse files
authored
chore: hourcekeeping, bump all (dev) deps (#381)
1 parent c894d76 commit 7d50d38

40 files changed

+7982
-7045
lines changed

.editorconfig

+8-8
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
root = true
1+
root=true
22

33
[*]
4-
indent_style = space
5-
indent_size = 2
6-
tab_width = 2
7-
end_of_line = lf
8-
charset = utf-8
9-
trim_trailing_whitespace = true
10-
insert_final_newline = true
4+
indent_style=space
5+
indent_size=2
6+
tab_width=2
7+
end_of_line=lf
8+
charset=utf-8
9+
trim_trailing_whitespace=true
10+
insert_final_newline=true

.env.yarn

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
CONFIG_PREFER_PRETTIER=1
2+
NODE_OPTIONS="--no-warnings=ESLintRCWarning"

.eslintignore

-7
This file was deleted.

.eslintrc

-16
This file was deleted.

.github/workflows/ci.yml

+7-11
Original file line numberDiff line numberDiff line change
@@ -29,15 +29,7 @@ jobs:
2929
steps:
3030
- uses: actions/checkout@v4
3131

32-
- name: Setup target Node.js to enable Corepack
33-
uses: actions/setup-node@v4
34-
with:
35-
node-version: ${{ matrix.node }}
36-
37-
- name: Enable Corepack
38-
run: corepack enable
39-
40-
- name: Setup Node.js ${{ matrix.node }} with cache
32+
- name: Setup Node.js ${{ matrix.node }}
4133
uses: actions/setup-node@v4
4234
with:
4335
node-version: ${{ matrix.node }}
@@ -46,8 +38,12 @@ jobs:
4638
- name: Install Dependencies
4739
run: yarn --immutable
4840

49-
- name: Build, Lint and Test
50-
run: yarn run-s build lint test typecov
41+
- name: Build and Typecov
42+
run: yarn run-s build typecov
5143
env:
5244
EFF_NO_LINK_RULES: true
5345
PARSER_NO_WATCH: true
46+
47+
- name: Lint and Test
48+
if: ${{ matrix.node != 16}}
49+
run: yarn run-s lint test

.github/workflows/release.yml

-3
Original file line numberDiff line numberDiff line change
@@ -21,9 +21,6 @@ jobs:
2121
# This makes Actions fetch all Git history so that Changesets can generate changelogs with the correct commits
2222
fetch-depth: 0
2323

24-
- name: Enable Corepack
25-
run: corepack enable
26-
2724
- name: Setup Node.js LTS
2825
uses: actions/setup-node@v4
2926
with:

.github/workflows/size-limit.yml

-3
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,6 @@ jobs:
2020
steps:
2121
- uses: actions/checkout@v4
2222

23-
- name: Enable Corepack
24-
run: corepack enable
25-
2623
- name: Setup Node.js LTS
2724
uses: actions/setup-node@v4
2825
with:

.gitignore

+2
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22
.type-coverage
33
.yarn/*
44
!.yarn/plugins
5+
!.yarn/releases
56
lib
67
node_modules
78
*.log
9+
.npmrc

.lintstagedrc.cjs

-1
This file was deleted.

.lintstagedrc.js

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export { default } from '@1stg/lint-staged/tsc'

.prettierignore

+2
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
1+
.yarn
12
dist
23
lib
34
node_modules
45
/pnpm-lock.yaml
6+
**/*.svg

.renovaterc

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"extends": [
3-
"@1stg"
3+
"github>1stG/configs"
44
]
55
}

.size-limit.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[
22
{
33
"path": "./lib/index.js",
4-
"limit": "3.2kB"
4+
"limit": "3.1kB"
55
}
66
]

.yarn/releases/yarn-4.7.0.cjs

+935
Large diffs are not rendered by default.

.yarnrc.yml

+3-1
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,6 @@ nodeLinker: node-modules
55
plugins:
66
- checksum: 37b2361b1502b2054e6779788c0e9bdd6a90ce49852a8cad2feda79b0614ec94f06fb6e78951f5f95429c610d7934dd077caa47413a0227378a102c55161616d
77
path: .yarn/plugins/plugin-prepare-lifecycle.cjs
8-
spec: "https://github.com/un-es/yarn-plugin-prepare-lifecycle/releases/download/v0.0.1/index.js"
8+
spec: 'https://github.com/un-es/yarn-plugin-prepare-lifecycle/releases/download/v0.0.1/index.js'
9+
10+
yarnPath: .yarn/releases/yarn-4.7.0.cjs

README.md

+40-38
Original file line numberDiff line numberDiff line change
@@ -72,37 +72,39 @@ const {
7272
createTypeScriptImportResolver,
7373
} = require('eslint-import-resolver-typescript')
7474

75-
module.exports = [{
76-
settings: {
77-
"import-x/resolver-next": [
78-
createTypeScriptImportResolver({
79-
alwaysTryTypes: true, // always try to resolve types under `<root>@types` directory even it doesn't contain any source code, like `@types/unist`
75+
module.exports = [
76+
{
77+
settings: {
78+
'import-x/resolver-next': [
79+
createTypeScriptImportResolver({
80+
alwaysTryTypes: true, // always try to resolve types under `<root>@types` directory even it doesn't contain any source code, like `@types/unist`
8081

81-
// Choose from one of the "project" configs below or omit to use <root>/tsconfig.json by default
82+
// Choose from one of the "project" configs below or omit to use <root>/tsconfig.json by default
8283

83-
// use <root>/path/to/folder/tsconfig.json
84-
project: "path/to/folder",
84+
// use <root>/path/to/folder/tsconfig.json
85+
project: 'path/to/folder',
8586

86-
// Multiple tsconfigs (Useful for monorepos)
87+
// Multiple tsconfigs (Useful for monorepos)
8788

88-
// use a glob pattern
89-
project: "packages/*/tsconfig.json",
89+
// use a glob pattern
90+
project: 'packages/*/tsconfig.json',
9091

91-
// use an array
92-
project: [
93-
"packages/module-a/tsconfig.json",
94-
"packages/module-b/tsconfig.json"
95-
],
92+
// use an array
93+
project: [
94+
'packages/module-a/tsconfig.json',
95+
'packages/module-b/tsconfig.json',
96+
],
9697

97-
// use an array of glob patterns
98-
project: [
99-
"packages/*/tsconfig.json",
100-
"other-packages/*/tsconfig.json"
101-
]
102-
}),
103-
]
104-
}
105-
}]
98+
// use an array of glob patterns
99+
project: [
100+
'packages/*/tsconfig.json',
101+
'other-packages/*/tsconfig.json',
102+
],
103+
}),
104+
],
105+
},
106+
},
107+
]
106108
```
107109

108110
But if you are using `eslint-plugin-import` or the older version of `eslint-plugin-import-x`, you can't use require/import:
@@ -153,11 +155,11 @@ Add the following to your `.eslintrc` config:
153155
"plugins": ["import"],
154156
"rules": {
155157
// turn on errors for missing imports
156-
"import/no-unresolved": "error"
158+
"import/no-unresolved": "error",
157159
},
158160
"settings": {
159161
"import/parsers": {
160-
"@typescript-eslint/parser": [".ts", ".tsx"]
162+
"@typescript-eslint/parser": [".ts", ".tsx"],
161163
},
162164
"import/resolver": {
163165
"typescript": {
@@ -176,17 +178,17 @@ Add the following to your `.eslintrc` config:
176178
// use an array
177179
"project": [
178180
"packages/module-a/tsconfig.json",
179-
"packages/module-b/tsconfig.json"
181+
"packages/module-b/tsconfig.json",
180182
],
181183

182184
// use an array of glob patterns
183185
"project": [
184186
"packages/*/tsconfig.json",
185-
"other-packages/*/tsconfig.json"
186-
]
187-
}
188-
}
189-
}
187+
"other-packages/*/tsconfig.json",
188+
],
189+
},
190+
},
191+
},
190192
}
191193
```
192194

@@ -210,7 +212,7 @@ Default:
210212
"node",
211213
"node-addons",
212214
"browser",
213-
"default"
215+
"default",
214216
]
215217
```
216218

@@ -227,7 +229,7 @@ Default:
227229
".js",
228230
".jsx",
229231
".json",
230-
".node"
232+
".node",
231233
]
232234
```
233235

@@ -242,11 +244,11 @@ Default:
242244
// `.tsx` can also be compiled as `.js`
243245
".tsx",
244246
".d.ts",
245-
".js"
247+
".js",
246248
],
247249
".jsx": [".tsx", ".d.ts", ".jsx"],
248250
".cjs": [".cts", ".d.cts", ".cjs"],
249-
".mjs": [".mts", ".d.mts", ".mjs"]
251+
".mjs": [".mts", ".d.mts", ".mjs"],
250252
}
251253
```
252254

@@ -268,7 +270,7 @@ Default:
268270
"module",
269271
"jsnext:main",
270272

271-
"main"
273+
"main",
272274
]
273275
```
274276

eslint.config.js

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
// @ts-check
2+
3+
import recommended from '@1stg/eslint-config'
4+
5+
/**
6+
* @import {TSESLint} from '@typescript-eslint/utils'
7+
* @type {TSESLint.FlatConfig.ConfigArray}
8+
*/
9+
const config = [
10+
{
11+
ignores: ['tests'],
12+
},
13+
...recommended,
14+
{
15+
files: ['dummy.js/*'],
16+
languageOptions: {
17+
globals: {
18+
module: false,
19+
},
20+
},
21+
},
22+
]
23+
24+
export default config

0 commit comments

Comments
 (0)