Crate include_js_codegen[][src]


Simmilar to include_str! from the stdlib but instead of including arbitrary files as &str it includes sytactically valid javascript from files as &JSStr. If the file contains invalid Javascript you will get a compiletime error.

Derive Macros

Derives the JSTemplate trait for a struct with named fields. This is simmilar to plain include_js! with the difference that the Javascript is not yet fully filled in, so a template engine (in this case Handlebars) to fill in the values at runtime.