Skip to content

Conversation

@Simolation
Copy link
Contributor

Description

This PR adds support for the handlebars package as hbs only works with express.
The handlebars package can be used with fastify.

It adds handlebars as another valid view engine option and then dynamically loads the handlebars package. The usage is exactly the same as with hbs.

Linked Issues

#469

Additional context

@rubiin
Copy link
Collaborator

rubiin commented Feb 11, 2024

@Simolation please fix the failed tests


## Fastify

To use handlebars with fastify, `handlebars` is used instead of `hbs`. Make sure to install it (`npm i handlebars`).
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have already installed it as a dependency in package.json, so need to add this make sure to install at readme.

@toonvanstrijp toonvanstrijp merged commit 3e7ffb1 into toonvanstrijp:main Nov 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants