From 88738971bfed1ec9f7e2565d8f428c5cbc2e314e Mon Sep 17 00:00:00 2001 From: Tiago Costa Date: Mon, 1 Apr 2019 17:21:24 +0100 Subject: [PATCH] Remove ts-loader from canvas storybook webpack config. (#33896) * chore(NA): remove ts-loader from canvas storybook webpack config. * chore(NA): use the correct preset. --- x-pack/plugins/canvas/.storybook/webpack.config.js | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/x-pack/plugins/canvas/.storybook/webpack.config.js b/x-pack/plugins/canvas/.storybook/webpack.config.js index 39e33c9613e44..2e09ae93fa326 100644 --- a/x-pack/plugins/canvas/.storybook/webpack.config.js +++ b/x-pack/plugins/canvas/.storybook/webpack.config.js @@ -17,7 +17,7 @@ module.exports = (_baseConfig, _env, config) => { include: /\.storybook/, loaders: 'babel-loader', options: { - presets: [require.resolve('@babel/preset-react')], + presets: [require.resolve('@kbn/babel-preset/webpack_preset')], }, }, ); @@ -55,15 +55,9 @@ module.exports = (_baseConfig, _env, config) => { test: /\.tsx?$/, use: [ { - loader: 'ts-loader', + loader: 'babel-loader', options: { - transpileOnly: true, - experimentalWatchApi: true, - onlyCompileBundledFiles: true, - configFile: require.resolve('../../../../tsconfig.json'), - compilerOptions: { - sourceMap: true, - }, + presets: [require.resolve('@kbn/babel-preset/webpack_preset')], }, }, require.resolve('react-docgen-typescript-loader'),