chore(frontend): typescript configuration
This commit is contained in:
parent
5a9ed747d2
commit
4cab9eafdf
5
.babelrc
5
.babelrc
@ -4,10 +4,11 @@
|
||||
"useBuiltIns": "usage",
|
||||
"targets": { "node": "current" }
|
||||
}
|
||||
]
|
||||
],
|
||||
["@babel/preset-typescript"]
|
||||
],
|
||||
"plugins": [
|
||||
["@babel/plugin-proposal-decorators", { "legacy": true }],
|
||||
["@babel/plugin-proposal-decorators", { "legacy": true, "version": "2023-11" }],
|
||||
["@babel/plugin-proposal-class-properties", { "loose": true }],
|
||||
["@babel/plugin-proposal-private-methods", { "loose": true }],
|
||||
["@babel/plugin-proposal-private-property-in-object", { "loose": true }],
|
||||
|
||||
@ -1,3 +1,3 @@
|
||||
SPDX-FileCopyrightText: 2022 Felix Hamann <felix.hamann@campus.lmu.de>,Sarah Vaupel <sarah.vaupel@ifi.lmu.de>,Sarah Vaupel <vaupel.sarah@campus.lmu.de>
|
||||
SPDX-FileCopyrightText: 2022-2024 Felix Hamann <felix.hamann@campus.lmu.de>,Sarah Vaupel <sarah.vaupel@ifi.lmu.de>,Sarah Vaupel <vaupel.sarah@campus.lmu.de>,David Mosbach <david.mosbach@uniworx.de>
|
||||
|
||||
SPDX-License-Identifier: AGPL-3.0-or-later
|
||||
|
||||
9
tsconfig.json
Normal file
9
tsconfig.json
Normal file
@ -0,0 +1,9 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"outDir": "./frontend/src/js",
|
||||
"module": "es6",
|
||||
"target": "es5",
|
||||
"allowJs": true,
|
||||
"moduleResolution": "node"
|
||||
}
|
||||
}
|
||||
3
tsconfig.json.license
Normal file
3
tsconfig.json.license
Normal file
@ -0,0 +1,3 @@
|
||||
SPDX-FileCopyrightText: 2024 David Mosbach <david.mosbach@uniworx.de>
|
||||
|
||||
SPDX-License-Identifier: AGPL-3.0-or-later
|
||||
@ -1,4 +1,4 @@
|
||||
// SPDX-FileCopyrightText: 2022 Gregor Kleen <gregor.kleen@ifi.lmu.de>,Sarah Vaupel <sarah.vaupel@ifi.lmu.de>,Sarah Vaupel <vaupel.sarah@campus.lmu.de>
|
||||
// SPDX-FileCopyrightText: 2022-2024 Gregor Kleen <gregor.kleen@ifi.lmu.de>,Sarah Vaupel <sarah.vaupel@ifi.lmu.de>,Sarah Vaupel <vaupel.sarah@campus.lmu.de>,David Mosbach <david.mosbach@uniworx.de>
|
||||
//
|
||||
// SPDX-License-Identifier: AGPL-3.0-or-later
|
||||
|
||||
@ -112,7 +112,7 @@ async function webpackConfig() {
|
||||
|
||||
entry: {
|
||||
main: [ path.resolve(__dirname, 'frontend/src', 'polyfill.js'),
|
||||
path.resolve(__dirname, 'frontend/src', 'main.js')
|
||||
path.resolve(__dirname, 'frontend/src', 'main.ts')
|
||||
]
|
||||
},
|
||||
|
||||
@ -266,6 +266,10 @@ async function webpackConfig() {
|
||||
})()
|
||||
],
|
||||
|
||||
resolve: {
|
||||
extensions: ['.js', '.ts', '.tsx']
|
||||
},
|
||||
|
||||
output: {
|
||||
chunkFilename: '[chunkhash].js',
|
||||
filename: '[chunkhash].js',
|
||||
|
||||
Reference in New Issue
Block a user