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: docs/config/shared-options.md
+3-3
Original file line number
Diff line number
Diff line change
@@ -345,12 +345,12 @@ Whether to support named imports from `.json` files.
345
345
346
346
## json.stringify
347
347
348
-
-**Type:**`boolean`
349
-
-**Default:**`false`
348
+
-**Type:**`boolean | 'auto'`
349
+
-**Default:**`'auto'`
350
350
351
351
If set to `true`, imported JSON will be transformed into `export default JSON.parse("...")` which is significantly more performant than Object literals, especially when the JSON file is large.
352
352
353
-
Enabling this disables named imports.
353
+
If set to `'auto'`, the data will be stringified only if [the data is bigger than 10kB](https://v8.dev/blog/cost-of-javascript-2019#json:~:text=A%20good%20rule%20of%20thumb%20is%20to%20apply%20this%20technique%20for%20objects%20of%2010%20kB%20or%20larger).
0 commit comments