mirror of
https://github.com/flarum/core.git
synced 2025-08-02 22:47:33 +02:00
Add configuration for global typings (#2)
Support for https://github.com/flarum/core/pull/2992
This commit is contained in:
@@ -19,8 +19,10 @@ A baseline `tsconfig.json` is provided below that you can modify as needed. This
|
|||||||
{
|
{
|
||||||
// Use Flarum's tsconfig as a starting point
|
// Use Flarum's tsconfig as a starting point
|
||||||
"extends": "flarum-tsconfig",
|
"extends": "flarum-tsconfig",
|
||||||
// This will match all .ts, .tsx, .d.ts, .js, .jsx files
|
// This will match all .ts, .tsx, .d.ts, .js, .jsx files in your `src` folder
|
||||||
"include": ["src/**/*"],
|
// and also tells your Typescript server to read core's global typings for
|
||||||
|
// access to `dayjs` and `$` in the global namespace.
|
||||||
|
"include": ["src/**/*", "../vendor/flarum/core/js/dist-typings/@types/**/*"],
|
||||||
"compilerOptions": {
|
"compilerOptions": {
|
||||||
// This will output typings to `dist-typings`
|
// This will output typings to `dist-typings`
|
||||||
"declarationDir": "./dist-typings",
|
"declarationDir": "./dist-typings",
|
||||||
|
Reference in New Issue
Block a user