This is an example app that demonstrates the use of bin2png. You can see it running at https://bin2png-example.netlify.com
The build is handled by parcel.
At build time, bin2png is used to convert a .wasm
file to a png image.
(See posthtml.config.js)
This image is then inlined as base64 inside an HTML file, and all the dependencies are bundled in a single HTML file using parcel-plugin-inliner.
At runtime, script.js
loads png2bin
to recreate the original .wasm
file, and uses it to load sql.js.