diff --git a/package.json b/package.json index c4a0dd9f..661d01d9 100644 --- a/package.json +++ b/package.json @@ -27,6 +27,7 @@ "@babel/preset-env": "^7.9.0", "@cypress/vue": "^3.0.0-beta.1", "@cypress/webpack-dev-server": "^1.3.1", + "@rollup/plugin-babel": "^5.3.0", "@rollup/plugin-node-resolve": "^13.0.4", "@typescript-eslint/eslint-plugin": "^4.28.5", "@typescript-eslint/parser": "^4.28.5", @@ -91,4 +92,4 @@ "engines": { "node": ">=12.17.0" } -} \ No newline at end of file +} diff --git a/scripts/config.js b/scripts/config.js index 11fddd07..7566a1b2 100644 --- a/scripts/config.js +++ b/scripts/config.js @@ -1,6 +1,7 @@ const path = require('path') const fs = require('fs-extra') const { nodeResolve } = require('@rollup/plugin-node-resolve') +const { babel } = require('@rollup/plugin-babel') const vue = require('rollup-plugin-vue') const css = require('rollup-plugin-css-only') const CleanCSS = require('clean-css') @@ -58,7 +59,8 @@ function createConfig (pkg, format) { }), vue({ css: false - }) + }), + babel({ babelHelpers: 'bundled' }) ] }, output: { diff --git a/yarn.lock b/yarn.lock index 247b8ccc..94ea0cdf 100644 --- a/yarn.lock +++ b/yarn.lock @@ -185,6 +185,13 @@ dependencies: "@babel/types" "^7.14.5" +"@babel/helper-module-imports@^7.10.4": + version "7.15.4" + resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.15.4.tgz#e18007d230632dea19b47853b984476e7b4e103f" + integrity sha512-jeAHZbzUwdW/xHgHQ3QmWR4Jg6j15q4w/gCfwZvtqOxoo5DKtLHk8Bsf4c5RZRC7NmLEs+ohkdq8jFefuvIxAA== + dependencies: + "@babel/types" "^7.15.4" + "@babel/helper-module-imports@^7.12.13", "@babel/helper-module-imports@^7.13.12", "@babel/helper-module-imports@^7.14.5": version "7.14.5" resolved "https://registry.yarnpkg.com/@babel/helper-module-imports/-/helper-module-imports-7.14.5.tgz#6d1a44df6a38c957aa7c312da076429f11b422f3" @@ -1016,6 +1023,14 @@ "@babel/helper-validator-identifier" "^7.14.9" to-fast-properties "^2.0.0" +"@babel/types@^7.15.4": + version "7.15.6" + resolved "https://registry.yarnpkg.com/@babel/types/-/types-7.15.6.tgz#99abdc48218b2881c058dd0a7ab05b99c9be758f" + integrity sha512-BPU+7QhqNjmWyDO0/vitH/CuhpV8ZmK1wpKva8nuyNF5MJfuRNWMc+hc14+u9xT93kvykMdncrJT19h74uB1Ig== + dependencies: + "@babel/helper-validator-identifier" "^7.14.9" + to-fast-properties "^2.0.0" + "@bcoe/v8-coverage@^0.2.3": version "0.2.3" resolved "https://registry.yarnpkg.com/@bcoe/v8-coverage/-/v8-coverage-0.2.3.tgz#75a2e8b51cb758a7553d6804a5932d7aace75c39" @@ -2169,6 +2184,14 @@ resolved "https://registry.yarnpkg.com/@polka/url/-/url-1.0.0-next.15.tgz#6a9d143f7f4f49db2d782f9e1c8839a29b43ae23" integrity sha512-15spi3V28QdevleWBNXE4pIls3nFZmBbUGrW9IVPwiQczuSb9n76TCB4bsk8TSel+I1OkHEdPhu5QKMfY6rQHA== +"@rollup/plugin-babel@^5.3.0": + version "5.3.0" + resolved "https://registry.yarnpkg.com/@rollup/plugin-babel/-/plugin-babel-5.3.0.tgz#9cb1c5146ddd6a4968ad96f209c50c62f92f9879" + integrity sha512-9uIC8HZOnVLrLHxayq/PTzw+uS25E14KPUBh5ktF+18Mjo5yK0ToMMx6epY0uEgkjwJw0aBW4x2horYXh8juWw== + dependencies: + "@babel/helper-module-imports" "^7.10.4" + "@rollup/pluginutils" "^3.1.0" + "@rollup/plugin-node-resolve@^13.0.4": version "13.0.4" resolved "https://registry.yarnpkg.com/@rollup/plugin-node-resolve/-/plugin-node-resolve-13.0.4.tgz#b10222f4145a019740acb7738402130d848660c0"