prettier-config-nick2bad4u 1.0.6 → 1.0.8
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/README.md +4 -4
- package/index.d.ts +11 -2
- package/package.json +6 -16
- package/preset.mjs +8 -1
package/README.md
CHANGED
|
@@ -25,9 +25,9 @@ The package is ESM-first and exports the config from `preset.mjs`.
|
|
|
25
25
|
### Option 2: prettier.config.mjs
|
|
26
26
|
|
|
27
27
|
```js
|
|
28
|
-
import
|
|
28
|
+
import prettierConfig from "prettier-config-nick2bad4u";
|
|
29
29
|
|
|
30
|
-
export default
|
|
30
|
+
export default prettierConfig;
|
|
31
31
|
```
|
|
32
32
|
|
|
33
33
|
### Option 2a: named import
|
|
@@ -41,10 +41,10 @@ export default config;
|
|
|
41
41
|
### Option 3: extend with local overrides
|
|
42
42
|
|
|
43
43
|
```js
|
|
44
|
-
import
|
|
44
|
+
import prettierConfig from "prettier-config-nick2bad4u";
|
|
45
45
|
|
|
46
46
|
export default {
|
|
47
|
-
...
|
|
47
|
+
...prettierConfig,
|
|
48
48
|
printWidth: 100,
|
|
49
49
|
};
|
|
50
50
|
```
|
package/index.d.ts
CHANGED
|
@@ -1,6 +1,15 @@
|
|
|
1
1
|
import type { Config } from "prettier";
|
|
2
2
|
|
|
3
|
-
/**
|
|
3
|
+
/** Named export — use when you want to spread or inspect individual options. */
|
|
4
4
|
export declare const config: Readonly<Config>;
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
/**
|
|
7
|
+
* Default export (bound as `prettierConfig`) — use this form to avoid
|
|
8
|
+
* triggering `import-x/no-named-as-default` in consuming projects:
|
|
9
|
+
*
|
|
10
|
+
* ```js
|
|
11
|
+
* import prettierConfig from "prettier-config-nick2bad4u";
|
|
12
|
+
* ```
|
|
13
|
+
*/
|
|
14
|
+
declare const prettierConfig: Readonly<Config>;
|
|
15
|
+
export default prettierConfig;
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://www.schemastore.org/package.json",
|
|
3
3
|
"name": "prettier-config-nick2bad4u",
|
|
4
|
-
"version": "1.0.
|
|
4
|
+
"version": "1.0.8",
|
|
5
5
|
"private": false,
|
|
6
6
|
"description": "Shared Prettier config for Nick2bad4u projects.",
|
|
7
7
|
"keywords": [
|
|
@@ -66,7 +66,7 @@
|
|
|
66
66
|
"lint:prettier": "prettier . --log-level warn --cache --cache-location=.cache/.prettier-cache --cache-strategy=content --check",
|
|
67
67
|
"lint:prettier:fix": "prettier . --log-level warn --cache --cache-location=.cache/.prettier-cache --cache-strategy=content --write",
|
|
68
68
|
"lint:publint": "publint",
|
|
69
|
-
"lint:secretlint": "secretlint --secretlintrc .secretlintrc.
|
|
69
|
+
"lint:secretlint": "secretlint --secretlintrc .secretlintrc.cjs --secretlintignore .gitignore \"**/*\"",
|
|
70
70
|
"lint:yaml": "eslint --cache --cache-strategy content --cache-location .cache/.eslintcache \"**/*.{yml,yaml}\"",
|
|
71
71
|
"lint:yaml:fix": "npm run lint:yaml -- --fix",
|
|
72
72
|
"package:check": "npm pack --dry-run",
|
|
@@ -84,6 +84,7 @@
|
|
|
84
84
|
},
|
|
85
85
|
"dependencies": {
|
|
86
86
|
"@softonus/prettier-plugin-duplicate-remover": "^1.1.2",
|
|
87
|
+
"npm-check-updates": "^22.1.0",
|
|
87
88
|
"prettier-plugin-ini": "^1.3.0",
|
|
88
89
|
"prettier-plugin-interpolated-html-tags": "^2.0.1",
|
|
89
90
|
"prettier-plugin-jsdoc": "^1.8.0",
|
|
@@ -98,29 +99,18 @@
|
|
|
98
99
|
},
|
|
99
100
|
"devDependencies": {
|
|
100
101
|
"@arethetypeswrong/cli": "^0.18.2",
|
|
101
|
-
"@secretlint/secretlint-rule-anthropic": "^12.3.1",
|
|
102
|
-
"@secretlint/secretlint-rule-aws": "^12.3.1",
|
|
103
|
-
"@secretlint/secretlint-rule-database-connection-string": "^12.3.1",
|
|
104
|
-
"@secretlint/secretlint-rule-gcp": "^12.3.1",
|
|
105
|
-
"@secretlint/secretlint-rule-github": "^12.3.1",
|
|
106
|
-
"@secretlint/secretlint-rule-no-dotenv": "^12.3.1",
|
|
107
|
-
"@secretlint/secretlint-rule-no-homedir": "^12.3.1",
|
|
108
|
-
"@secretlint/secretlint-rule-npm": "^12.3.1",
|
|
109
|
-
"@secretlint/secretlint-rule-openai": "^12.3.1",
|
|
110
|
-
"@secretlint/secretlint-rule-pattern": "^12.3.1",
|
|
111
|
-
"@secretlint/secretlint-rule-privatekey": "^12.3.1",
|
|
112
|
-
"@secretlint/secretlint-rule-secp256k1-privatekey": "^12.3.1",
|
|
113
102
|
"@types/node": "^25.6.0",
|
|
114
103
|
"@vitest/coverage-v8": "^4.1.5",
|
|
115
104
|
"cross-env": "^10.1.0",
|
|
116
105
|
"eslint": "^10.3.0",
|
|
117
|
-
"eslint-config-nick2bad4u": "^1.0.
|
|
106
|
+
"eslint-config-nick2bad4u": "^1.0.9",
|
|
118
107
|
"git-cliff": "^2.13.1",
|
|
119
|
-
"npm-package-json-lint": "^10.
|
|
108
|
+
"npm-package-json-lint": "^10.4.0",
|
|
120
109
|
"picocolors": "^1.1.1",
|
|
121
110
|
"prettier": "^3.8.3",
|
|
122
111
|
"publint": "^0.3.18",
|
|
123
112
|
"secretlint": "^12.3.1",
|
|
113
|
+
"secretlint-config-nick2bad4u": "^1.0.2",
|
|
124
114
|
"sort-package-json": "^3.6.1",
|
|
125
115
|
"typescript": "^6.0.3",
|
|
126
116
|
"vite": "^8.0.10",
|
package/preset.mjs
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
import sharedPrettierConfig from "./.prettierrc.json" with { type: "json" };
|
|
2
2
|
|
|
3
|
+
/** Named export — use when you want to spread or inspect individual options. */
|
|
3
4
|
export const config = Object.freeze(sharedPrettierConfig);
|
|
4
5
|
|
|
5
|
-
|
|
6
|
+
/**
|
|
7
|
+
* Default export — distinct binding so consuming projects don't trigger
|
|
8
|
+
* `import-x/no-named-as-default` when they write `import prettierConfig from
|
|
9
|
+
* "prettier-config-nick2bad4u"`.
|
|
10
|
+
*/
|
|
11
|
+
const prettierConfig = config;
|
|
12
|
+
export default prettierConfig;
|