0
0
mirror of https://github.com/wagtail/wagtail.git synced 2024-11-22 02:18:39 +01:00
wagtail/tsconfig.json
Lovelyfin00 8e2e66bef0 Update tsconfig to align with latest browser usage
- Added the target : es2021 option because least browser support is safari 14.
- Added the dom.iterable option in order for the spread operator to work on DOM elements.
- Added the "strictPropertyInitialization": true option. This ensures that any class constructor property that is declared must be initialized or set.
- Added the "forceConsistentCasingInFileNames": true option to ensure that different filesystem renaming issues will be flagged early
- Re-order the config to be alphabetical
2022-12-11 15:32:47 +10:00

30 lines
939 B
JSON

{
"compilerOptions": {
"allowJs": true,
"downlevelIteration": true,
"esModuleInterop": true,
"forceConsistentCasingInFileNames": true,
"jsx": "react",
"lib": ["DOM", "DOM.iterable"],
"moduleResolution": "node",
"noImplicitAny": false, // TODO: Enable once all existing code is typed
"noUnusedLocals": true,
"noUnusedParameters": true,
"strictNullChecks": true,
"strictPropertyInitialization": true, // Requires `--strictNullChecks` be enabled in order to take effect
"target": "ES2021" // Since lowest browser support is for Safari 14
},
"files": [
"client/src/index.ts",
"client/src/custom.d.ts",
"client/storybook/stories.d.ts"
],
"include": ["src", "wagtail"],
"exclude": [
"node_modules",
"static",
// Files with template syntax.
"wagtail/contrib/search_promotions/templates/wagtailsearchpromotions/includes/searchpromotions_formset.js"
]
}