Add an option for custom runtime (#3612)
This commit is contained in:
24
packages/babel-plugin-transform-runtime/test/fixtures/runtime/custom-runtime/expected.js
vendored
Normal file
24
packages/babel-plugin-transform-runtime/test/fixtures/runtime/custom-runtime/expected.js
vendored
Normal file
@@ -0,0 +1,24 @@
|
||||
import _regeneratorRuntime from "foo/regenerator";
|
||||
import _Symbol from "foo/core-js/symbol";
|
||||
|
||||
var _marked = [giveWord].map(_regeneratorRuntime.mark);
|
||||
|
||||
import foo, * as bar from "someModule";
|
||||
|
||||
export const myWord = _Symbol("abc");
|
||||
export function giveWord() {
|
||||
return _regeneratorRuntime.wrap(function giveWord$(_context) {
|
||||
while (1) switch (_context.prev = _context.next) {
|
||||
case 0:
|
||||
_context.next = 2;
|
||||
return myWord;
|
||||
|
||||
case 2:
|
||||
case "end":
|
||||
return _context.stop();
|
||||
}
|
||||
}, _marked[0], this);
|
||||
}
|
||||
|
||||
foo;
|
||||
bar;
|
||||
Reference in New Issue
Block a user