Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support transforming import source for wasm #15870

Merged
2 changes: 1 addition & 1 deletion Makefile.js

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions Makefile.source.mjs
Expand Up @@ -450,14 +450,14 @@ target["bootstrap-flow"] = function () {

target["new-version-checklist"] = function () {
// eslint-disable-next-line no-constant-condition
if (0) {
if (1) {
console.log(
`
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!! !!!!!!
!!!!!! Write any important message here, and change the !!!!!!
!!!!!! if (0) above to if (1) !!!!!!
!!!!!! Set the minimum required core version in the !!!!!!
!!!!!! import source transform to the new minor. !!!!!!
!!!!!! !!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
Expand Down
3 changes: 3 additions & 0 deletions packages/babel-plugin-proposal-import-wasm-source/.npmignore
@@ -0,0 +1,3 @@
src
test
*.log
19 changes: 19 additions & 0 deletions packages/babel-plugin-proposal-import-wasm-source/README.md
@@ -0,0 +1,19 @@
# @babel/plugin-proposal-import-wasm-source

> Transform source phase imports (`import source ... from '...'`) to work in browsers and Node.js, assuming that the imported source is a WebAssembly module.
See our website [@babel/plugin-proposal-import-wasm-source](https://babeljs.io/docs/babel-plugin-proposal-import-wasm-source) for more information.

## Install

Using npm:

```sh
npm install --save-dev @babel/plugin-proposal-import-wasm-source
```

or using yarn:

```sh
yarn add @babel/plugin-proposal-import-wasm-source --dev
```
65 changes: 65 additions & 0 deletions packages/babel-plugin-proposal-import-wasm-source/package.json
@@ -0,0 +1,65 @@
{
"name": "@babel/plugin-proposal-import-wasm-source",
"version": "7.22.5",
"description": "Transform source phase imports (`import source ... from '...'`) to work in browsers and Node.js, assuming that the imported source is a WebAssembly module.",
"repository": {
"type": "git",
"url": "https://github.com/babel/babel.git",
"directory": "packages/babel-plugin-proposal-import-wasm-source"
},
"homepage": "https://babel.dev/docs/en/next/babel-plugin-proposal-import-wasm-source",
"license": "MIT",
"publishConfig": {
"access": "public"
},
"main": "./lib/index.js",
"exports": {
".": "./lib/index.js",
"./package.json": "./package.json"
},
"keywords": [
"babel-plugin",
"import",
"source",
"phase",
"wasm",
"WebAssembly",
"assertions",
"proposal",
"stage-3"
],
"dependencies": {
"@babel/helper-compilation-targets": "workspace:^",
"@babel/helper-module-imports": "workspace:^",
"@babel/helper-plugin-utils": "workspace:^",
"@babel/plugin-syntax-import-source": "workspace:^"
},
"peerDependencies": {
"@babel/core": "^7.22.0"
},
"devDependencies": {
"@babel/core": "workspace:^",
"@babel/helper-plugin-test-runner": "workspace:^"
},
"engines": {
"node": ">=6.9.0"
},
"author": "The Babel Team (https://babel.dev/team)",
"type": "commonjs",
"conditions": {
"USE_ESM": [
{
"type": "module"
},
null
],
"BABEL_8_BREAKING": [
{
"engines": {
"node": "^16.20.0 || ^18.16.0 || >=20.0.0"
}
},
{}
]
}
}