worsier 2.8.0 → 2.9.0
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 +1 -1
- package/configuration_schema.json +6 -0
- package/dist/types.d.ts +1 -0
- package/package.json +9 -9
package/README.md
CHANGED
|
@@ -16,7 +16,7 @@ pnpm exec worsier --write .
|
|
|
16
16
|
|
|
17
17
|
The CLI uses its defaults when no configuration file is present. Run `pnpm exec worsier --init` to create a complete typed `worsier.jsonc`.
|
|
18
18
|
|
|
19
|
-
For `.vue` files, Worsier formats inline `<script>` and `<script setup>` blocks using JavaScript, JSX, TypeScript, or TSX. Templates, styles, custom blocks, external `src` scripts, and unknown languages remain byte-for-byte unchanged.
|
|
19
|
+
For `.vue` files, Worsier formats inline `<script>` and `<script setup>` blocks using JavaScript, JSX, TypeScript, or TSX while preserving their existing top-level indentation. Templates, styles, custom blocks, external `src` scripts, and unknown languages remain byte-for-byte unchanged.
|
|
20
20
|
|
|
21
21
|
## Programmatic API
|
|
22
22
|
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
},
|
|
35
35
|
"statementSpacing": {
|
|
36
36
|
"imports": "separate",
|
|
37
|
+
"returnStatements": "separate",
|
|
37
38
|
"typeAliases": "separate",
|
|
38
39
|
"variableDeclarations": "separate"
|
|
39
40
|
},
|
|
@@ -89,6 +90,7 @@
|
|
|
89
90
|
"$ref": "#/$defs/StatementSpacingConfig",
|
|
90
91
|
"default": {
|
|
91
92
|
"imports": "separate",
|
|
93
|
+
"returnStatements": "separate",
|
|
92
94
|
"typeAliases": "separate",
|
|
93
95
|
"variableDeclarations": "separate"
|
|
94
96
|
}
|
|
@@ -133,6 +135,10 @@
|
|
|
133
135
|
"$ref": "#/$defs/StatementSpacingMode",
|
|
134
136
|
"default": "separate"
|
|
135
137
|
},
|
|
138
|
+
"returnStatements": {
|
|
139
|
+
"$ref": "#/$defs/StatementSpacingMode",
|
|
140
|
+
"default": "separate"
|
|
141
|
+
},
|
|
136
142
|
"typeAliases": {
|
|
137
143
|
"$ref": "#/$defs/StatementSpacingMode",
|
|
138
144
|
"default": "separate"
|
package/dist/types.d.ts
CHANGED
|
@@ -20,6 +20,7 @@ export interface SemicolonConfig {
|
|
|
20
20
|
}
|
|
21
21
|
export interface StatementSpacingConfig {
|
|
22
22
|
imports?: 'separate' | 'compact' | 'off';
|
|
23
|
+
returnStatements?: 'separate' | 'compact' | 'off';
|
|
23
24
|
typeAliases?: 'separate' | 'compact' | 'off';
|
|
24
25
|
variableDeclarations?: 'separate' | 'compact' | 'off';
|
|
25
26
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "worsier",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.9.0",
|
|
4
4
|
"description": "A focused JavaScript, TypeScript, and Vue SFC script formatter powered by Rust",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -49,14 +49,14 @@
|
|
|
49
49
|
]
|
|
50
50
|
},
|
|
51
51
|
"optionalDependencies": {
|
|
52
|
-
"worsier-darwin-arm64": "2.
|
|
53
|
-
"worsier-win32-arm64-msvc": "2.
|
|
54
|
-
"worsier-linux-arm64-gnu": "2.
|
|
55
|
-
"worsier-linux-arm64-musl": "2.
|
|
56
|
-
"worsier-darwin-x64": "2.
|
|
57
|
-
"worsier-win32-x64-msvc": "2.
|
|
58
|
-
"worsier-linux-x64-gnu": "2.
|
|
59
|
-
"worsier-linux-x64-musl": "2.
|
|
52
|
+
"worsier-darwin-arm64": "2.9.0",
|
|
53
|
+
"worsier-win32-arm64-msvc": "2.9.0",
|
|
54
|
+
"worsier-linux-arm64-gnu": "2.9.0",
|
|
55
|
+
"worsier-linux-arm64-musl": "2.9.0",
|
|
56
|
+
"worsier-darwin-x64": "2.9.0",
|
|
57
|
+
"worsier-win32-x64-msvc": "2.9.0",
|
|
58
|
+
"worsier-linux-x64-gnu": "2.9.0",
|
|
59
|
+
"worsier-linux-x64-musl": "2.9.0"
|
|
60
60
|
},
|
|
61
61
|
"devDependencies": {
|
|
62
62
|
"@types/node": "26.2.0",
|