source: trip-planner-front/node_modules/@babel/helper-module-imports/lib/is-module.js@ fa375fe

Last change on this file since fa375fe was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 381 bytes
Line 
1"use strict";
2
3Object.defineProperty(exports, "__esModule", {
4 value: true
5});
6exports.default = isModule;
7
8function isModule(path) {
9 const {
10 sourceType
11 } = path.node;
12
13 if (sourceType !== "module" && sourceType !== "script") {
14 throw path.buildCodeFrameError(`Unknown sourceType "${sourceType}", cannot transform.`);
15 }
16
17 return path.node.sourceType === "module";
18}
Note: See TracBrowser for help on using the repository browser.