From da66dbcb4d069b68fda8897e17b6ddaba7dedded Mon Sep 17 00:00:00 2001 From: Marek Libra Date: Thu, 29 Mar 2018 10:04:48 +0200 Subject: [PATCH] Add babel-loader for node_modules/@novnc The noVNC npm package dist is ES6, it needs to be babelized for the storybook. --- package-lock.json | 8 ++++---- package.json | 1 + storybook/webpack.config.js | 4 ++++ 3 files changed, 9 insertions(+), 4 deletions(-) diff --git a/package-lock.json b/package-lock.json index f6833e5235f..15d574085ed 100644 --- a/package-lock.json +++ b/package-lock.json @@ -549,7 +549,7 @@ "airbnb-js-shims": "1.4.1", "autoprefixer": "7.2.5", "babel-core": "6.26.0", - "babel-loader": "7.1.2", + "babel-loader": "7.1.4", "babel-plugin-react-docgen": "1.8.2", "babel-plugin-transform-regenerator": "6.26.0", "babel-plugin-transform-runtime": "6.23.0", @@ -1716,9 +1716,9 @@ } }, "babel-loader": { - "version": "7.1.2", - "resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-7.1.2.tgz", - "integrity": "sha512-jRwlFbINAeyDStqK6Dd5YuY0k5YuzQUvlz2ZamuXrXmxav3pNqe9vfJ402+2G+OmlJSXxCOpB6Uz0INM7RQe2A==", + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-7.1.4.tgz", + "integrity": "sha512-/hbyEvPzBJuGpk9o80R0ZyTej6heEOr59GoEUtn8qFKbnx4cJm9FWES6J/iv644sYgrtVw9JJQkjaLW/bqb5gw==", "dev": true, "requires": { "find-cache-dir": "1.0.0", diff --git a/package.json b/package.json index b67fdfbb9f7..6a6509cf5d1 100644 --- a/package.json +++ b/package.json @@ -47,6 +47,7 @@ "babel-core": "^6.26.0", "babel-eslint": "^8.1.2", "babel-jest": "^22.0.4", + "babel-loader": "^7.1.4", "babel-plugin-transform-class-properties": "^6.24.1", "babel-plugin-transform-export-extensions": "^6.22.0", "babel-plugin-transform-object-assign": "^6.22.0", diff --git a/storybook/webpack.config.js b/storybook/webpack.config.js index 5d5951865eb..610ce075a66 100644 --- a/storybook/webpack.config.js +++ b/storybook/webpack.config.js @@ -79,6 +79,10 @@ module.exports = { mimetype: 'image/svg+xml', name: '[name].[ext]' } + }, + { + test: /node_modules\/@novnc/, + loader: 'babel-loader' } ] }