packages/babel-core/test/fixtures/async/plugin-mjs/plugin.mjs
raw| 1 | // Until Jest supports native mjs, we must simulate it 🤷 |
| 2 | module.exports = new Promise(resolve => |
| 3 | resolve({ |
| 4 | default: function plugin({ types: t }) { |
| 5 | return { |
| 6 | visitor: { |
| 7 | Program(path) { |
| 8 | path.pushContainer("body", t.stringLiteral("success")); |
| 9 | }, |
| 10 | }, |
| 11 | }; |
| 12 | }, |
| 13 | }) |
| 14 | ); |
| 15 | |
| 16 | module.exports.__esModule = true; |