@homeflare/config 0.1.0 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +19 -16
- package/package.json +3 -6
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Timothy Schneider <tim@taslabs.net>
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,15 +1,19 @@
|
|
|
1
1
|
# @homeflare/config
|
|
2
2
|
|
|
3
|
-
Shared TypeScript, oxlint and oxfmt configuration
|
|
4
|
-
|
|
3
|
+
Shared TypeScript, oxlint and oxfmt configuration. One place to change a rule, rather
|
|
4
|
+
than one copy per repo that drifts.
|
|
5
|
+
|
|
6
|
+
```sh
|
|
7
|
+
bun add -D @homeflare/config
|
|
8
|
+
```
|
|
5
9
|
|
|
6
10
|
## tsconfig
|
|
7
11
|
|
|
8
12
|
```jsonc
|
|
9
|
-
//
|
|
13
|
+
// an app or a Worker
|
|
10
14
|
{ "extends": "@homeflare/config/tsconfig.base.json" }
|
|
11
15
|
|
|
12
|
-
//
|
|
16
|
+
// a package that publishes types
|
|
13
17
|
{ "extends": "@homeflare/config/tsconfig.lib.json" }
|
|
14
18
|
```
|
|
15
19
|
|
|
@@ -17,29 +21,28 @@ change a rule, rather than one copy per repo that drifts.
|
|
|
17
21
|
⛔ Both are needed together — `isolatedDeclarations` alone is TS5069, even under
|
|
18
22
|
`--noEmit`.
|
|
19
23
|
|
|
20
|
-
|
|
24
|
+
The base turns on `strict`, plus the three flags that catch the most runtime bugs:
|
|
25
|
+
`noUncheckedIndexedAccess` (`arr[0]` is `T | undefined`), `exactOptionalPropertyTypes`,
|
|
26
|
+
and `noFallthroughCasesInSwitch`.
|
|
21
27
|
|
|
22
|
-
|
|
23
|
-
`eslint-config-*` style resolution. The path into `node_modules` is written out:
|
|
28
|
+
## oxlint
|
|
24
29
|
|
|
25
30
|
```json
|
|
26
|
-
{
|
|
27
|
-
"extends": ["./node_modules/@homeflare/config/oxlintrc.json"],
|
|
28
|
-
"rules": {
|
|
29
|
-
// project-specific overrides go here
|
|
30
|
-
}
|
|
31
|
-
}
|
|
31
|
+
{ "extends": ["./node_modules/@homeflare/config/oxlintrc.json"] }
|
|
32
32
|
```
|
|
33
33
|
|
|
34
|
-
|
|
34
|
+
⚠️ oxlint's `extends` takes **file paths**, not package names — there is no
|
|
35
|
+
`eslint-config-*` style resolution, so the path into `node_modules` is written out.
|
|
35
36
|
|
|
36
|
-
|
|
37
|
-
silently uses its defaults, and the symptom is a formatter that rewrites your quotes.
|
|
37
|
+
## oxfmt
|
|
38
38
|
|
|
39
39
|
```sh
|
|
40
40
|
cp node_modules/@homeflare/config/oxfmtrc.json .oxfmtrc.json
|
|
41
41
|
```
|
|
42
42
|
|
|
43
|
+
⚠️ The file must be named `.oxfmtrc.json` — **with the leading dot**. Without it oxfmt
|
|
44
|
+
silently uses its defaults, and the symptom is a formatter that rewrites your quotes.
|
|
45
|
+
|
|
43
46
|
## License
|
|
44
47
|
|
|
45
48
|
MIT © Timothy Schneider
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@homeflare/config",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.2",
|
|
4
4
|
"description": "Shared tsconfig, oxlint and oxfmt configuration for HomeFlare projects.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Timothy Schneider",
|
|
@@ -14,7 +14,8 @@
|
|
|
14
14
|
"tsconfig.lib.json",
|
|
15
15
|
"oxlintrc.json",
|
|
16
16
|
"oxfmtrc.json",
|
|
17
|
-
"README.md"
|
|
17
|
+
"README.md",
|
|
18
|
+
"LICENSE"
|
|
18
19
|
],
|
|
19
20
|
"type": "module",
|
|
20
21
|
"exports": {
|
|
@@ -26,9 +27,5 @@
|
|
|
26
27
|
},
|
|
27
28
|
"publishConfig": {
|
|
28
29
|
"access": "public"
|
|
29
|
-
},
|
|
30
|
-
"scripts": {
|
|
31
|
-
"build": "echo 'config: nothing to build'",
|
|
32
|
-
"clean": "echo 'config: nothing to clean'"
|
|
33
30
|
}
|
|
34
31
|
}
|