Closed jshjohnson closed 7 years ago
Hi jshjohnson.
Unfortunately, this plugin only accepts a single page as start file. You can still build multiple files via the environment variable, something like entry: process.env.page === 1 ? first.js : last.js
or use multiple webpack configs (gag).
A more appropriate solution would be a handlebars-loader, which is currently not open source. I will add a note here as soon as its available.
@sagold isn't this opensource: https://github.com/altano/handlebars-loader?
@Dinistro The handlebars-loader https://github.com/altano/handlebars-loader does return a template string to perform rendering on the client-side. But this plugin creates the final html on server-side.
@jshjohnson At Süddeutsche Zeitung we rewrote the plugin as a loader, to support multiple handlebars-files which is now available here https://github.com/sueddeutsche/handlebars-render-loader.
Regards.
This is something I needed too and solved in my pull request here https://github.com/sagold/handlebars-webpack-plugin/pull/13
I merged the pr and released the plugin with version v0.2.0
Hi,
Does this plugin support multiple pages? For example, the entry point would be a glob of Handlebar files and the output would be the directory for each of those compiled pages to go into?
Similar to how Assemble works.
Thanks