DEV: Add jsconfig (#17800)

This enables intelligent IDE features like "Go To Reference" to function correctly within the Discourse core codebase
This commit is contained in:
Peter Wagenet 2022-08-04 14:50:47 -07:00 committed by GitHub
parent e0ece3a77e
commit d0cbc61619
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
7 changed files with 79 additions and 0 deletions

View File

@ -0,0 +1,12 @@
{
"extends": "../../../../jsconfig.base.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"admin/*": ["./addon/*"],
"discourse/*": ["../discourse/app/*"],
"discourse-common/*": ["../discourse-common/addon/*"],
"pretty-text/*": ["../pretty-text/addon/*"],
}
},
}

View File

@ -0,0 +1,11 @@
{
"extends": "../../../../jsconfig.base.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"discourse-widget-hbs/*": ["./addon/*"],
"discourse/*": ["../discourse/app/*"],
"discourse-common/*": ["../discourse-common/addon/*"]
}
},
}

View File

@ -0,0 +1,13 @@
{
"extends": "../../../../jsconfig.base.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"discourse/*": ["./app/*"],
"discourse-common/*": ["../discourse-common/addon/*"],
"pretty-text/*": ["../pretty-text/addon/*"],
"select-kit/*": ["../select-kit/addon/*"],
"wizard/*": ["../wizard/addon/*"],
}
},
}

View File

@ -0,0 +1,11 @@
{
"extends": "../../../../jsconfig.base.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"pretty-text/*": ["./addon/*"],
"discourse/*": ["../discourse/app/*"],
"discourse-common/*": ["../discourse-common/addon/*"]
}
},
}

View File

@ -0,0 +1,11 @@
{
"extends": "../../../../jsconfig.base.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"select-kit/*": ["./addon/*"],
"discourse/*": ["../discourse/app/*"],
"discourse-common/*": ["../discourse-common/addon/*"],
}
},
}

View File

@ -0,0 +1,11 @@
{
"extends": "../../../../jsconfig.base.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"wizard/*": ["./addon/*"],
"discourse/*": ["../discourse/app/*"],
"discourse-common/*": ["../discourse-common/addon/*"],
}
},
}

10
jsconfig.base.json Normal file
View File

@ -0,0 +1,10 @@
{
"compilerOptions": {
"target": "es2020",
"module": "amd",
"experimentalDecorators": true,
},
"exclude": [
"**/node_modules"
],
}