source: imaps-frontend/node_modules/@babel/plugin-transform-optional-catch-binding/lib/index.js@ 79a0317

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

F4 Finalna Verzija

  • Property mode set to 100644
File size: 737 bytes
Line 
1"use strict";
2
3Object.defineProperty(exports, "__esModule", {
4 value: true
5});
6exports.default = void 0;
7var _helperPluginUtils = require("@babel/helper-plugin-utils");
8var _default = exports.default = (0, _helperPluginUtils.declare)(api => {
9 api.assertVersion("^7.0.0-0 || >8.0.0-alpha <8.0.0-beta");
10 return {
11 name: "transform-optional-catch-binding",
12 manipulateOptions: (_, parser) => parser.plugins.push("optionalCatchBinding"),
13 visitor: {
14 CatchClause(path) {
15 if (!path.node.param) {
16 const uid = path.scope.generateUidIdentifier("unused");
17 const paramPath = path.get("param");
18 paramPath.replaceWith(uid);
19 }
20 }
21 }
22 };
23});
24
25//# sourceMappingURL=index.js.map
Note: See TracBrowser for help on using the repository browser.