eleventy-plugin-vento 4.0.0-beta.0 → 4.0.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.
- package/CHANGELOG.md +31 -1
- package/dist/index.js +6 -6
- package/package.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# eleventy-plugin-vento
|
|
2
2
|
|
|
3
|
-
## 4.0.0
|
|
3
|
+
## 4.0.0
|
|
4
4
|
|
|
5
5
|
### Major Changes
|
|
6
6
|
|
|
@@ -24,6 +24,36 @@
|
|
|
24
24
|
|
|
25
25
|
These changes also include `.d.ts` generation as part of the build step. If you're using `11ty.ts`'s `defineConfig` function, it will pick the types from this plugin up automatically. (resolves #22)
|
|
26
26
|
|
|
27
|
+
## 4.0.0-beta.0
|
|
28
|
+
|
|
29
|
+
### Major Changes
|
|
30
|
+
|
|
31
|
+
- fc80b5f: Removed ignore tag `{{! ... }}` syntax. As mentioned in the 3.3.0 release notes, the now preferred way to "pass through" tags is with string literals.
|
|
32
|
+
|
|
33
|
+
You should update code with `{{! ... }}` to be `{{ '{{ }}' }}` like so:
|
|
34
|
+
|
|
35
|
+
```diff
|
|
36
|
+
- {{! if condition }}
|
|
37
|
+
+ {{ '{{ if condition }}' }}
|
|
38
|
+
do something
|
|
39
|
+
- {{! /if }}
|
|
40
|
+
+ {{ '{{ /if }}' }}
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
While more verbose, this change ensures that there isn't any ambiguity between a tag that needs ignoring and JS negation expressions.
|
|
44
|
+
|
|
45
|
+
### Minor Changes
|
|
46
|
+
|
|
47
|
+
- 2b5f337: Rewrite project in Typescript and add a build/packaging step for releases and testing.
|
|
48
|
+
|
|
49
|
+
These changes also include `.d.ts` generation as part of the build step. If you're using `11ty.ts`'s `defineConfig` function, it will pick the types from this plugin up automatically. (resolves #22)
|
|
50
|
+
|
|
51
|
+
## 3.4.0
|
|
52
|
+
|
|
53
|
+
### Minor Changes
|
|
54
|
+
|
|
55
|
+
- 8c6b8a2: Update `ventojs` to v1.12.11
|
|
56
|
+
|
|
27
57
|
## 3.3.0
|
|
28
58
|
|
|
29
59
|
### Minor Changes
|
package/dist/index.js
CHANGED
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
import path from "node:path";
|
|
3
3
|
import autotrimPlugin, { defaultTags as autotrimDefaultTags } from "ventojs/plugins/auto_trim.js";
|
|
4
4
|
|
|
5
|
-
// src/
|
|
5
|
+
// src/create-vento-interface.ts
|
|
6
6
|
import { default as ventojs } from "ventojs";
|
|
7
7
|
|
|
8
|
-
// src/
|
|
8
|
+
// src/create-vento-tag.ts
|
|
9
9
|
function createVentoTag(spec) {
|
|
10
10
|
const IS_PAIRED = spec.group === "pairedShortcodes";
|
|
11
11
|
const tag = (env, code, output, tokens) => {
|
|
@@ -45,7 +45,7 @@ function createVentoTag(spec) {
|
|
|
45
45
|
});
|
|
46
46
|
}
|
|
47
47
|
|
|
48
|
-
// src/
|
|
48
|
+
// src/utils.ts
|
|
49
49
|
import createDebugger from "debug";
|
|
50
50
|
var debugBaseNamespace = "Eleventy:Vento";
|
|
51
51
|
var DEBUG = {
|
|
@@ -75,8 +75,8 @@ function runCompatibilityCheck(config) {
|
|
|
75
75
|
}
|
|
76
76
|
}
|
|
77
77
|
|
|
78
|
-
// src/
|
|
79
|
-
function
|
|
78
|
+
// src/create-vento-interface.ts
|
|
79
|
+
function createVentoInterface(options) {
|
|
80
80
|
const env = ventojs(options);
|
|
81
81
|
env.utils._11tyFns = { shortcodes: {}, pairedShortcodes: {} };
|
|
82
82
|
env.utils._11tyCtx = {};
|
|
@@ -191,7 +191,7 @@ function VentoPlugin(eleventyConfig, userOptions) {
|
|
|
191
191
|
options.plugins.push(autotrimPlugin({ tags: [...tagSet] }));
|
|
192
192
|
}
|
|
193
193
|
DEBUG.setup("Initializing Vento environment");
|
|
194
|
-
const engine =
|
|
194
|
+
const engine = createVentoInterface(options.ventoOptions);
|
|
195
195
|
DEBUG.setup("Loading plugins: %o", options.plugins);
|
|
196
196
|
engine.loadPlugins(options.plugins);
|
|
197
197
|
if (options.filters) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eleventy-plugin-vento",
|
|
3
|
-
"version": "4.0.0
|
|
3
|
+
"version": "4.0.0",
|
|
4
4
|
"description": "Adds support for the Vento templating language to Eleventy.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"engines": {
|
|
@@ -36,18 +36,18 @@
|
|
|
36
36
|
"license": "MIT",
|
|
37
37
|
"dependencies": {
|
|
38
38
|
"debug": "4.3.7",
|
|
39
|
-
"ventojs": "1.12.
|
|
39
|
+
"ventojs": "1.12.11"
|
|
40
40
|
},
|
|
41
41
|
"devDependencies": {
|
|
42
42
|
"11ty.ts": "0.0.5",
|
|
43
43
|
"@11ty/eleventy": "3.0.0",
|
|
44
44
|
"@changesets/cli": "2.27.9",
|
|
45
|
-
"@eslint/js": "9.
|
|
45
|
+
"@eslint/js": "9.14.0",
|
|
46
46
|
"@types/debug": "4.1.12",
|
|
47
47
|
"@types/eslint-config-prettier": "6.11.3",
|
|
48
48
|
"@types/eslint__js": "8.42.3",
|
|
49
49
|
"@types/node": "22.8.4",
|
|
50
|
-
"eslint": "9.
|
|
50
|
+
"eslint": "9.14.0",
|
|
51
51
|
"eslint-config-prettier": "9.1.0",
|
|
52
52
|
"eslint-plugin-unicorn": "56.0.0",
|
|
53
53
|
"tsup": "8.3.5",
|