const Encore = require('@symfony/webpack-encore');


Encore
    .setOutputPath('public/build/')
    .setPublicPath('/build')
    .cleanupOutputBeforeBuild()
    .enableBuildNotifications()
    .addEntry('js/app', './assets/js/app.ts')

    //.addStyleEntry('global', './assets/styles/global.scss')
    .addStyleEntry('style/app', ['./assets/style/app.scss'])
    .addStyleEntry('style/scoreboard', ['./assets/style/scoreboard.scss'])
    .addStyleEntry('style/scorecard', ['./assets/style/scorecard.scss'])

    .configureBabel((babelConfig) => {
        babelConfig.presets.push('es2017');
    })
    .enableSassLoader((sassOptions) => {
        sassOptions.precision = 10;
    }, {
        resolveUrlLoader: false
    })
    .enableTypeScriptLoader((tsConfig) => {
    })
    .enablePostCssLoader()

    .autoProvideVariables({
        '$': 'jquery',
        'jQuery': 'jquery',
        'window.jQuery': 'jquery'
    })

    .enableSourceMaps(!Encore.isProduction())
    .enableVersioning(Encore.isProduction())
;

module.exports = Encore.getWebpackConfig();

@@ -1,8 +1,38 @@
+const path = require('path');%0A
 const En
@@ -812,15 +812,181 @@
 able
-PostCss
+ForkedTypeScriptTypesChecking((tsForkedConfig) =%3E %7B%0A        tsForkedConfig.vue = true;%0A        tsForkedConfig.tslint = true;%0A    %7D)%0A    .enablePostCssLoader()%0A    .enableVue
 Load
@@ -1210,22 +1210,20 @@
 %0A;%0A%0A
-module.exports
+const config
  = E
@@ -1248,8 +1248,196 @@
 nfig();%0A
+config.resolve.alias = %7B%0A    ...config.resolve.alias,%0A    '@': path.resolve(__dirname, './assets/js'),%0A    'style': path.resolve(__dirname, './assets/style'),%0A%7D;%0A%0Amodule.exports = config;%0A

use forked typescript types checking plugin in webpack.config.js