source: imaps-frontend/node_modules/@babel/plugin-transform-dynamic-import/lib/index.js

main
Last change on this file was 79a0317, checked in by stefan toskovski <stefantoska84@…>, 4 days ago

F4 Finalna Verzija

  • Property mode set to 100644
File size: 1.3 KB
Line 
1"use strict";
2
3Object.defineProperty(exports, "__esModule", {
4 value: true
5});
6exports.default = void 0;
7var _helperPluginUtils = require("@babel/helper-plugin-utils");
8const SUPPORTED_MODULES = new Set(["commonjs", "amd", "systemjs"]);
9const MODULES_NOT_FOUND = `\
10@babel/plugin-transform-dynamic-import depends on a modules
11transform plugin. Supported plugins are:
12 - @babel/plugin-transform-modules-commonjs ^7.4.0
13 - @babel/plugin-transform-modules-amd ^7.4.0
14 - @babel/plugin-transform-modules-systemjs ^7.4.0
15
16If you are using Webpack or Rollup and thus don't want
17Babel to transpile your imports and exports, you can use
18the @babel/plugin-syntax-dynamic-import plugin and let your
19bundler handle dynamic imports.
20`;
21var _default = exports.default = (0, _helperPluginUtils.declare)(api => {
22 api.assertVersion(7);
23 return {
24 name: "transform-dynamic-import",
25 manipulateOptions: (_, parser) => parser.plugins.push("dynamicImport"),
26 pre() {
27 this.file.set("@babel/plugin-proposal-dynamic-import", "7.25.9");
28 },
29 visitor: {
30 Program() {
31 const modules = this.file.get("@babel/plugin-transform-modules-*");
32 if (!SUPPORTED_MODULES.has(modules)) {
33 throw new Error(MODULES_NOT_FOUND);
34 }
35 }
36 }
37 };
38});
39
40//# sourceMappingURL=index.js.map
Note: See TracBrowser for help on using the repository browser.