boxwood 0.78.0 → 0.79.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +3 -3
  2. package/index.js +1 -1
  3. package/package.json +4 -1
package/README.md CHANGED
@@ -42,7 +42,7 @@ const { compile } = require("boxwood")
42
42
  const { join } = require("path")
43
43
  // ...
44
44
  const path = join(__dirname, "index.js")
45
- const { template } = await compile(path)
45
+ const { template } = compile(path)
46
46
  // ...
47
47
  const html = template({ foo: "bar" })
48
48
  console.log(html)
@@ -121,13 +121,13 @@ const assert = require("node:assert")
121
121
  const { compile } = require("boxwood")
122
122
 
123
123
  test("banner renders a title", async () => {
124
- const { template } = await compile(__dirname)
124
+ const { template } = compile(__dirname)
125
125
  const html = template({ title: "foo" })
126
126
  assert(html.includes("<h1>foo</h1>"))
127
127
  })
128
128
 
129
129
  test("banner renders an optional description", async () => {
130
- const { template } = await compile(__dirname)
130
+ const { template } = compile(__dirname)
131
131
  const html = template({ title: "foo", description: "bar" })
132
132
  assert(html.includes("<h1>foo</h1>"))
133
133
  assert(html.includes("<p>bar</p>"))
package/index.js CHANGED
@@ -3,7 +3,7 @@ const { readFileSync } = require("fs")
3
3
  const csstree = require("css-tree")
4
4
  const toHash = require("string-hash")
5
5
 
6
- async function compile(path) {
6
+ function compile(path) {
7
7
  const fn = require(path)
8
8
  return {
9
9
  template() {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "boxwood",
3
- "version": "0.78.0",
3
+ "version": "0.79.0",
4
4
  "description": "Compile HTML templates into JS",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -64,5 +64,8 @@
64
64
  "dependencies": {
65
65
  "css-tree": "^2.3.1",
66
66
  "string-hash": "^1.1.3"
67
+ },
68
+ "prettier": {
69
+ "semi": false
67
70
  }
68
71
  }