Skip to content

Commit

Permalink
webpack: add temporary TS configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
dsevillamartin committed Jun 21, 2020
1 parent ca962bf commit 0a72f6b
Show file tree
Hide file tree
Showing 4 changed files with 216 additions and 4 deletions.
204 changes: 204 additions & 0 deletions js/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions js/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
"private": true,
"name": "@flarum/core",
"dependencies": {
"@babel/plugin-syntax-dynamic-import": "^7.8.3",
"@babel/preset-typescript": "^7.10.1",
"bootstrap": "^3.4.1",
"classnames": "^2.2.5",
"color-thief-browser": "^2.0.2",
Expand Down
3 changes: 0 additions & 3 deletions js/tsconfig.json

This file was deleted.

11 changes: 10 additions & 1 deletion js/webpack.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,14 @@ module.exports = merge(config(), {
},
plugins: [
new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/)
]
],

// temporary TS configuration
resolve: {
extensions: ['.ts', '.tsx', '.js', '.json'],
},
});

module.exports['module'].rules[0].test = /\.(tsx?|js)$/;
module.exports['module'].rules[0].use.options.presets.push('@babel/preset-typescript');
module.exports['module'].rules[0].use.options.plugins.push('@babel/plugin-syntax-dynamic-import');

0 comments on commit 0a72f6b

Please sign in to comment.