Skip to content

Commit

Permalink
Merge 031c89c into 5b2a8c0
Browse files Browse the repository at this point in the history
  • Loading branch information
mbland committed Jan 11, 2024
2 parents 5b2a8c0 + 031c89c commit c2c8ce7
Show file tree
Hide file tree
Showing 14 changed files with 538 additions and 20 deletions.
7 changes: 7 additions & 0 deletions .eslintrc
Expand Up @@ -50,5 +50,12 @@
"no-console": [
"error", { "allow": [ "warn", "error" ]}
]
},
"settings": {
"jsdoc": {
"preferredTypes": {
"Object": "object"
}
}
}
}
16 changes: 2 additions & 14 deletions README.md
Expand Up @@ -2,10 +2,8 @@

[Rollup][] plugin to precompile [Handlebars][] templates into [JavaScript modules][]

_**Status**: I've still got a bit of work to do before publishing v1.0.0. I need
to add tests based on the mbland/tomcat-servlet-testing-example project from
whence this came and add more documentation. I plan to finish this by
2024-01-11._
_**Note**: I still need to add more documentation, but the plugin is fully
functional and tested._

Source: <https://github.com/mbland/rollup-plugin-handlebars-precompiler>

Expand Down Expand Up @@ -52,16 +50,6 @@ Each generated Handlebars template module exports two functions:
Most of the time, you'll want to use the default export, imported as
`Template()` by convention.

## Configuration

## Motivation

## Examples

My [mbland/tomcat-servlet-testing-example][] project

### Component pattern

## Development

Uses [pnpm][] and [Vitest][] for building and testing. The [Vitest browser
Expand Down
11 changes: 11 additions & 0 deletions lib/template.d.ts
@@ -0,0 +1,11 @@
/*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/

declare module "*.hbs" {
export const RawTemplate: HandlebarsTemplateDelegate
export default function (context: any, options?: RuntimeOptions):
DocumentFragment
}
3 changes: 3 additions & 0 deletions package.json
Expand Up @@ -44,8 +44,11 @@
"jsdoc": "^4.0.2",
"jsdoc-cli-wrapper": "^1.0.4",
"jsdoc-plugin-typescript": "^2.2.1",
"jsdom": "^23.2.0",
"rollup": "^4.9.4",
"test-page-opener": "^1.0.5",
"typescript": "^5.3.3",
"vite": "^5.0.11",
"vitest": "^1.1.3"
},
"dependencies": {
Expand Down

0 comments on commit c2c8ce7

Please sign in to comment.