embed_module

Macro embed_module 

Source
macro_rules! embed_module {
    ($($x: expr),*) => { ... };
}
Expand description

Create a module loader that embeds files from the filesystem at build time. This is useful for bundling assets with the binary.

By default will error if the total file size exceeds 1MB. This can be changed by specifying the max_size parameter.

The embedded module will only contain files that have the .js, .mjs, or .cjs extension.