You can embed files using --embed-file , which places them inside the emitted JS (works ok for a small number of files). There is also NODEFS which lets you mount directories of the underlying filesystem, and access them directly.
On Wed, Jul 15, 2015 at 1:55 PM, Klaus <[email protected]> wrote: > I've successfully been using the file_packager.py to package data files > for my ports in the browser, but i just noticed the following: > > using preloaded data can only be done on a web page or in a web worker'; > > > When running ports from node, how are they able to load data? Directly > from the filesystem, relative to where the script is, like a normal > executable? If not, is there a way to package data for them? > > -- > You received this message because you are subscribed to the Google Groups > "emscripten-discuss" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "emscripten-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
