Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/vituum/vite-plugin-handlebars
⚡️💡 Vite plugin for Handlebars, transforms hbs templates into HTML
https://github.com/vituum/vite-plugin-handlebars
Last synced: 2 months ago
JSON representation
⚡️💡 Vite plugin for Handlebars, transforms hbs templates into HTML
- Host: GitHub
- URL: https://github.com/vituum/vite-plugin-handlebars
- Owner: vituum
- License: mit
- Created: 2022-08-24T09:25:21.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-11-17T11:52:15.000Z (about 1 year ago)
- Last Synced: 2024-04-25T13:20:47.140Z (9 months ago)
- Language: JavaScript
- Size: 31.3 KB
- Stars: 4
- Watchers: 1
- Forks: 2
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- fucking-awesome-vite - @vituum/vite-plugin-handlebars - Handlebars template engine support, transforms `.hbs` templates to `.html`. (Plugins / Framework-agnostic Plugins)
- awesome-vite - @vituum/vite-plugin-handlebars - Handlebars template engine support, transforms `.hbs` templates to `.html`. (Plugins / Framework-agnostic Plugins)
README
# ⚡️💡 ViteHandlebars
```js
import handlebars from '@vituum/vite-plugin-handlebars'export default {
plugins: [
handlebars()
],
build: {
rollupOptions: {
input: ['index.hbs.html']
}
}
}
```* Read the [docs](https://vituum.dev/plugins/handlebars.html) to learn more about the plugin options.
* Use with [Vituum](https://vituum.dev) to get multi-page support.## Basic usage
```html
{{> "path/to/template.hbs"}}
```
or
```html{
"template": "path/to/template.hbs",
"title": "Hello world"
}
```### Requirements
- [Node.js LTS (16.x)](https://nodejs.org/en/download/)
- [Vite](https://vitejs.dev/)