git ssb

0+

wanderer🌟 / js-primea-wasm-container



Tree: 69dfa6d2b66e206f048fb0432ddf61cb1743a42c

Files: 69dfa6d2b66e206f048fb0432ddf61cb1743a42c / tests / buildTests.js

350 bytesRaw
1const wast2wasm = require('wast2wasm')
2const fs = require('fs')
3
4const files = fs.readdirSync(`${__dirname}/wast`)
5for (let file of files) {
6 const wast = fs.readFileSync(`${__dirname}/wast/${file}`).toString()
7 wast2wasm(wast).then(wasm => {
8 file = file.split('.')[0]
9 fs.writeFileSync(`${__dirname}/wasm/${file}.wasm`, wasm.buffer)
10 })
11}
12

Built with git-ssb-web