You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: inlang/packages/paraglide/paraglide-js/docs-api/compiler-options.md
+15-11Lines changed: 15 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -40,7 +40,7 @@ The output will look like this:
40
40
41
41
> `optional`**cleanOutdir**: `boolean`
42
42
43
-
Defined in: [compiler-options.ts:280](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
43
+
Defined in: [compiler-options.ts:284](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
44
44
45
45
Whether to clean the output directory before writing the new files.
46
46
@@ -111,7 +111,7 @@ The name of the cookie to use for the cookie strategy.
Defined in: [compiler-options.ts:209](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
114
+
Defined in: [compiler-options.ts:213](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
115
115
116
116
Replaces AsyncLocalStorage with a synchronous implementation.
117
117
@@ -126,7 +126,7 @@ leak into another concurrent request.
126
126
127
127
> `optional`**emitGitIgnore**: `boolean`
128
128
129
-
Defined in: [compiler-options.ts:223](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
129
+
Defined in: [compiler-options.ts:227](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
130
130
131
131
If `emitGitIgnore` is set to `true` a `.gitignore` file will be emitted in the output directory. Defaults to `true`.
132
132
@@ -170,13 +170,17 @@ true
170
170
171
171
> `optional`**emitTsDeclarations**: `boolean`
172
172
173
-
Defined in: [compiler-options.ts:188](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
173
+
Defined in: [compiler-options.ts:192](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
174
174
175
175
Emit `.d.ts` files for the generated output using the TypeScript compiler.
176
176
177
-
Enable this to give IDEs fresh, explicit typings for generated message modules
178
-
(useful when using `locale-modules` during development). Requires `typescript`
179
-
to be resolvable in your toolchain.
177
+
Useful when `allowJs: true` cannot be set in your `tsconfig.json`
178
+
(e.g., due to project constraints or conflicting compiler options).
179
+
180
+
Requires `typescript` to be resolvable in your toolchain.
181
+
182
+
**Note:** Enabling this option reduces compiler speed because TypeScript
183
+
needs to generate declaration files for all output modules.
180
184
181
185
##### Example
182
186
@@ -222,7 +226,7 @@ false
222
226
223
227
> `optional`**fs**: `any`
224
228
225
-
Defined in: [compiler-options.ts:287](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
229
+
Defined in: [compiler-options.ts:291](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
226
230
227
231
The file system to use. Defaults to `await import('node:fs')`.
228
232
@@ -232,7 +236,7 @@ Useful for testing the paraglide compiler by mocking the fs.
Defined in: [compiler-options.ts:198](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
239
+
Defined in: [compiler-options.ts:202](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
236
240
237
241
Whether to include an eslint-disable comment at the top of each .js file.
Defined in: [compiler-options.ts:274](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
308
+
Defined in: [compiler-options.ts:278](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
305
309
306
310
The `outputStructure` defines how modules are structured in the output.
307
311
@@ -403,7 +407,7 @@ Custom strategies with the pattern `custom-[A-Za-z0-9]+` are supported.
Defined in: [compiler-options.ts:192](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
410
+
Defined in: [compiler-options.ts:196](https://github.com/opral/monorepo/tree/main/inlang/packages/paraglide/paraglide-js/src/compiler/compiler-options.ts)
0 commit comments