Files: 2696b0ddd05bbef598f8aec13320e0c97f0d4176 / tests / buildTests.js
350 bytesRaw
1 | const wast2wasm = require('wast2wasm') |
2 | const fs = require('fs') |
3 | |
4 | const files = fs.readdirSync(`${__dirname}/wast`) |
5 | for (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