Last change
on this file was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago |
initial commit
|
-
Property mode
set to
100644
|
File size:
784 bytes
|
Line | |
---|
1 | "use strict";
|
---|
2 |
|
---|
3 | Object.defineProperty(exports, "__esModule", {
|
---|
4 | value: true
|
---|
5 | });
|
---|
6 | exports.default = void 0;
|
---|
7 |
|
---|
8 | var _helperPluginUtils = require("@babel/helper-plugin-utils");
|
---|
9 |
|
---|
10 | var _pluginSyntaxNumericSeparator = require("@babel/plugin-syntax-numeric-separator");
|
---|
11 |
|
---|
12 | function remover({
|
---|
13 | node
|
---|
14 | }) {
|
---|
15 | var _extra$raw;
|
---|
16 |
|
---|
17 | const {
|
---|
18 | extra
|
---|
19 | } = node;
|
---|
20 |
|
---|
21 | if (extra != null && (_extra$raw = extra.raw) != null && _extra$raw.includes("_")) {
|
---|
22 | extra.raw = extra.raw.replace(/_/g, "");
|
---|
23 | }
|
---|
24 | }
|
---|
25 |
|
---|
26 | var _default = (0, _helperPluginUtils.declare)(api => {
|
---|
27 | api.assertVersion(7);
|
---|
28 | return {
|
---|
29 | name: "proposal-numeric-separator",
|
---|
30 | inherits: _pluginSyntaxNumericSeparator.default,
|
---|
31 | visitor: {
|
---|
32 | NumericLiteral: remover,
|
---|
33 | BigIntLiteral: remover
|
---|
34 | }
|
---|
35 | };
|
---|
36 | });
|
---|
37 |
|
---|
38 | exports.default = _default; |
---|
Note:
See
TracBrowser
for help on using the repository browser.