mirror of
https://github.com/tinymce/tinymce.git
synced 2025-07-21 11:32:37 +00:00

* TINY-7654: Upgrade to latest ts-loader and webpack for demos * TINY-7654: Upgrade to bedrock 13 * TINY-7654: Reworked how TinyMCE demos are done to work better with project references * TINY-7654: Tweaks/patches to try to improve compile time * TINY-7654: Upgrade to webpack-dev-server 4 (cherry picked from commit 45e8d7891cf502bd03db08da193011b340557a7e) * TINY-8299: Let grunt-webpack merge the config for us. Made the webpack config lazy to speed up initial grunt load. Fix some issues with the Alloy webpack-dev-server config. * TINY-8299: Remove ES5 spec that was brought in from an old branch * TINY-8299: Removed extra argument that was missed in the cleanup * TINY-8299: removed old `grunt webpack` task that we don't use anymore * TINY-8299: Corrected contributing guide to match how webpack-dev-server is now used * TINY-8299: Fixed harmless console error in model demo Co-authored-by: Lee Newson <lee.newson@tiny.cloud>
57 lines
1.1 KiB
JavaScript
57 lines
1.1 KiB
JavaScript
const ForkTsCheckerWebpackPlugin = require('fork-ts-checker-webpack-plugin');
|
|
const TsConfigPathsPlugin = require('tsconfig-paths-webpack-plugin');
|
|
const path = require('path');
|
|
|
|
module.exports = {
|
|
entry: './src/demo/ts/ephox/dragster/demo/DragsterDemo.ts',
|
|
devtool: 'source-map',
|
|
mode: 'development',
|
|
target: ['web'],
|
|
|
|
resolve: {
|
|
extensions: ['.ts', '.js'],
|
|
plugins: [
|
|
new TsConfigPathsPlugin({
|
|
extensions: ['.ts', '.js']
|
|
}),
|
|
]
|
|
},
|
|
|
|
module: {
|
|
rules: [
|
|
{
|
|
test: /\.js$/,
|
|
resolve: {
|
|
fullySpecified: false
|
|
}
|
|
},
|
|
|
|
{
|
|
test: /\.js$/,
|
|
use: ['source-map-loader'],
|
|
enforce: 'pre'
|
|
},
|
|
|
|
{
|
|
test: /\.ts$/,
|
|
use: [{
|
|
loader: 'ts-loader',
|
|
options: {
|
|
transpileOnly: true,
|
|
projectReferences: true
|
|
}
|
|
}]
|
|
}
|
|
]
|
|
},
|
|
|
|
plugins: [
|
|
new ForkTsCheckerWebpackPlugin({ async: true })
|
|
],
|
|
|
|
output: {
|
|
filename: 'demo.js',
|
|
path: path.resolve(__dirname, './scratch/compiled')
|
|
}
|
|
};
|