1
1
mirror of https://github.com/c8r/x0.git synced 2024-08-17 01:10:32 +03:00

Add .ts / .tsx to resolvable extensions

To allow .ts and .tsx files webpack.config.js must be updated
with resolve.extensions parameter
This will ensure, that .ts and .tsx extensions must not be explicitly added in relative imports
This commit is contained in:
Tobias Golbs 2018-08-26 22:29:33 +02:00
parent aaab8da11f
commit 2490f00d08

View File

@ -2,6 +2,9 @@
* It is necessary to add the ts-loader for .tsx files
*/
module.exports = {
resolve: {
extensions: [".js", "md", "mdx", "jsx", ".ts", ".tsx"],
},
module: {
rules: [
{ test: /\.tsx?$/, loader: "ts-loader" }