Skip to content

Handling wasm-pack before pnpm install #1848

Answered by d-corler
d-corler asked this question in Q&A
Discussion options

You must be logged in to vote

Yes, maybe with a decoy package.json

📁 shared
│
└── 📁 example project
    │
    ├─── .moon.yml
    │
    ├─── package.json (decoy)
    │
    └─── 📁 pkg (out of wasm-pack)
         │
         ├─── package.json
         │
       [...]
# Decoy
{
  "name": "example-wasm",
  "files": [
    "pkg/example_wasm_bg.wasm",
    "pkg/example_wasm.js",
    "pkg/example_wasm.d.ts"
  ],
  "main": "pkg/example_schemas_wasm.js",
  "types": "pkg/example_schemas_wasm.d.ts"
}

We can keep a "sync" by adding a script to copy and tweak it from pkg.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@d-corler
Comment options

Answer selected by d-corler
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants