@memberjunction/templates 4.0.0 → 4.1.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/README.md +116 -319
- package/dist/TemplateEngine.d.ts +1 -1
- package/dist/TemplateEngine.d.ts.map +1 -1
- package/dist/TemplateEngine.js +1 -1
- package/dist/TemplateEngine.js.map +1 -1
- package/package.json +9 -9
package/README.md
CHANGED
|
@@ -1,17 +1,57 @@
|
|
|
1
1
|
# @memberjunction/templates
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Server-side template rendering engine for MemberJunction, built on Nunjucks. Extends `TemplateEngineBase` with rendering capabilities, custom filters, and MJ-specific extensions for AI prompt integration and recursive template embedding.
|
|
4
|
+
|
|
5
|
+
## Architecture
|
|
6
|
+
|
|
7
|
+
```mermaid
|
|
8
|
+
graph TD
|
|
9
|
+
subgraph "@memberjunction/templates"
|
|
10
|
+
A[TemplateEngineServer] --> B[Nunjucks Environment]
|
|
11
|
+
A --> C[Template Cache]
|
|
12
|
+
A --> D[TemplateEntityLoader]
|
|
13
|
+
B --> E[Custom Filters]
|
|
14
|
+
B --> F[Extensions]
|
|
15
|
+
F --> G[AIPrompt Extension]
|
|
16
|
+
F --> H[TemplateEmbed Extension]
|
|
17
|
+
end
|
|
18
|
+
|
|
19
|
+
subgraph "Base Layer"
|
|
20
|
+
I["TemplateEngineBase<br/>(from base-types)"]
|
|
21
|
+
end
|
|
22
|
+
|
|
23
|
+
A -->|extends| I
|
|
24
|
+
|
|
25
|
+
subgraph "Rendering"
|
|
26
|
+
J[Template Entity] --> K[Validation]
|
|
27
|
+
K --> L[Merge Defaults]
|
|
28
|
+
L --> M[Nunjucks Render]
|
|
29
|
+
M --> N[TemplateRenderResult]
|
|
30
|
+
end
|
|
31
|
+
|
|
32
|
+
style A fill:#2d6a9f,stroke:#1a4971,color:#fff
|
|
33
|
+
style B fill:#2d8659,stroke:#1a5c3a,color:#fff
|
|
34
|
+
style C fill:#7c5295,stroke:#563a6b,color:#fff
|
|
35
|
+
style G fill:#b8762f,stroke:#8a5722,color:#fff
|
|
36
|
+
style H fill:#b8762f,stroke:#8a5722,color:#fff
|
|
37
|
+
style I fill:#2d6a9f,stroke:#1a4971,color:#fff
|
|
38
|
+
style N fill:#2d8659,stroke:#1a5c3a,color:#fff
|
|
39
|
+
```
|
|
4
40
|
|
|
5
41
|
## Overview
|
|
6
42
|
|
|
7
|
-
This package
|
|
43
|
+
This package is the **server-side rendering engine** for MemberJunction templates. It is NOT used within Angular applications despite using Angular Universal internally for compilation.
|
|
44
|
+
|
|
45
|
+
**Key capabilities:**
|
|
8
46
|
|
|
9
|
-
- **Nunjucks
|
|
10
|
-
- **
|
|
11
|
-
- **
|
|
12
|
-
- **
|
|
13
|
-
- **
|
|
14
|
-
- **
|
|
47
|
+
- **Nunjucks Rendering**: Full Nunjucks template syntax with async support
|
|
48
|
+
- **Parameter Validation**: Validates input data against template parameter definitions before rendering
|
|
49
|
+
- **Default Value Merging**: Automatically applies parameter defaults with content-specific overrides
|
|
50
|
+
- **Template Caching**: Compiled Nunjucks templates are cached for performance
|
|
51
|
+
- **Custom Filters**: `json`, `jsoninline`, and `jsonparse` filters for JSON manipulation
|
|
52
|
+
- **Extensible**: Plugin system via `TemplateExtensionBase` for custom Nunjucks tags
|
|
53
|
+
- **AI Prompt Extension**: Execute AI prompts inline within templates
|
|
54
|
+
- **Template Embedding**: Recursively embed templates within other templates
|
|
15
55
|
|
|
16
56
|
## Installation
|
|
17
57
|
|
|
@@ -19,355 +59,112 @@ This package serves as the core templating engine for MemberJunction application
|
|
|
19
59
|
npm install @memberjunction/templates
|
|
20
60
|
```
|
|
21
61
|
|
|
22
|
-
## Key Features
|
|
23
|
-
|
|
24
|
-
### 1. Template Engine
|
|
25
|
-
|
|
26
|
-
- Manages template metadata and caching
|
|
27
|
-
- Provides both metadata-based and simple rendering APIs
|
|
28
|
-
- Integrates with MemberJunction's entity system
|
|
29
|
-
- Supports template validation and parameter checking
|
|
30
|
-
|
|
31
|
-
### 2. AI Prompt Extension
|
|
32
|
-
|
|
33
|
-
- Embeds AI-generated content directly in templates
|
|
34
|
-
- Supports multiple AI models (OpenAI, Groq, etc.)
|
|
35
|
-
- Configurable formatting options
|
|
36
|
-
- Seamless integration with MemberJunction's AI Engine
|
|
37
|
-
|
|
38
|
-
### 3. Template Embed Extension
|
|
39
|
-
|
|
40
|
-
- Recursive template inclusion with cycle detection
|
|
41
|
-
- Content type inheritance and fallbacks
|
|
42
|
-
- Data context passing and merging
|
|
43
|
-
- Error handling for missing templates
|
|
44
|
-
|
|
45
62
|
## Usage
|
|
46
63
|
|
|
47
|
-
###
|
|
64
|
+
### Rendering Templates
|
|
48
65
|
|
|
49
66
|
```typescript
|
|
50
67
|
import { TemplateEngineServer } from '@memberjunction/templates';
|
|
51
|
-
import { UserInfo } from '@memberjunction/core';
|
|
52
68
|
|
|
53
|
-
|
|
54
|
-
|
|
69
|
+
const engine = TemplateEngineServer.Instance;
|
|
70
|
+
await engine.Config(false, contextUser);
|
|
55
71
|
|
|
56
|
-
//
|
|
57
|
-
|
|
72
|
+
// Find and render a template
|
|
73
|
+
const template = engine.FindTemplate('Welcome Email');
|
|
74
|
+
const content = template.Content[0]; // First content variant
|
|
58
75
|
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
'
|
|
62
|
-
|
|
63
|
-
);
|
|
76
|
+
const result = await engine.RenderTemplate(template, content, {
|
|
77
|
+
userName: 'John Doe',
|
|
78
|
+
companyName: 'Acme Corp'
|
|
79
|
+
});
|
|
64
80
|
|
|
65
81
|
if (result.Success) {
|
|
66
|
-
console.log(result.Output); //
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
### Rendering with Template Metadata
|
|
71
|
-
|
|
72
|
-
```typescript
|
|
73
|
-
import { TemplateEngineServer } from '@memberjunction/templates';
|
|
74
|
-
import { TemplateContentEntity } from '@memberjunction/core-entities';
|
|
75
|
-
|
|
76
|
-
// Assume you have loaded a template entity and its content
|
|
77
|
-
const templateEntity = await templateEngine.GetTemplateByName('WelcomeEmail');
|
|
78
|
-
const templateContent = templateEntity.GetHighestPriorityContent();
|
|
79
|
-
|
|
80
|
-
// Render with validation
|
|
81
|
-
const result = await templateEngine.RenderTemplate(
|
|
82
|
-
templateEntity,
|
|
83
|
-
templateContent,
|
|
84
|
-
{
|
|
85
|
-
userName: 'John Doe',
|
|
86
|
-
accountType: 'Premium',
|
|
87
|
-
signupDate: new Date()
|
|
88
|
-
},
|
|
89
|
-
false // SkipValidation = false
|
|
90
|
-
);
|
|
91
|
-
|
|
92
|
-
if (!result.Success) {
|
|
93
|
-
console.error('Template rendering failed:', result.Message);
|
|
82
|
+
console.log(result.Output); // Rendered HTML/text
|
|
83
|
+
} else {
|
|
84
|
+
console.error(result.Message); // Validation or rendering error
|
|
94
85
|
}
|
|
95
86
|
```
|
|
96
87
|
|
|
97
|
-
###
|
|
98
|
-
|
|
99
|
-
```typescript
|
|
100
|
-
// In your template:
|
|
101
|
-
const templateText = `
|
|
102
|
-
Dear {{ userName }},
|
|
103
|
-
|
|
104
|
-
{% AIPrompt AIModel="gpt-4", AllowFormatting=false %}
|
|
105
|
-
Generate a personalized welcome message for a new {{ accountType }} customer
|
|
106
|
-
named {{ userName }} who just signed up for our service. Make it warm and
|
|
107
|
-
professional, highlighting the benefits of their account type.
|
|
108
|
-
{% endAIPrompt %}
|
|
109
|
-
|
|
110
|
-
Best regards,
|
|
111
|
-
The Team
|
|
112
|
-
`;
|
|
113
|
-
|
|
114
|
-
const result = await templateEngine.RenderTemplateSimple(templateText, {
|
|
115
|
-
userName: 'Sarah',
|
|
116
|
-
accountType: 'Enterprise'
|
|
117
|
-
});
|
|
118
|
-
```
|
|
119
|
-
|
|
120
|
-
### Using the Template Embed Extension
|
|
121
|
-
|
|
122
|
-
```typescript
|
|
123
|
-
// Main template
|
|
124
|
-
const mainTemplate = `
|
|
125
|
-
{% template "Header", type="HTML" %}
|
|
126
|
-
|
|
127
|
-
<div class="content">
|
|
128
|
-
<h1>Welcome {{ user.name }}</h1>
|
|
129
|
-
{% template "UserProfile", data={showDetails: true} %}
|
|
130
|
-
</div>
|
|
131
|
-
|
|
132
|
-
{% template "Footer" %}
|
|
133
|
-
`;
|
|
134
|
-
|
|
135
|
-
// The embedded templates will be loaded from the template metadata
|
|
136
|
-
// and rendered with the appropriate content type and data context
|
|
137
|
-
```
|
|
138
|
-
|
|
139
|
-
## API Reference
|
|
140
|
-
|
|
141
|
-
### TemplateEngineServer
|
|
142
|
-
|
|
143
|
-
The main template engine class that handles all template operations.
|
|
144
|
-
|
|
145
|
-
#### Methods
|
|
146
|
-
|
|
147
|
-
##### `Config(forceRefresh?: boolean, contextUser?: UserInfo, provider?: IMetadataProvider): Promise<void>`
|
|
148
|
-
|
|
149
|
-
Configures the template engine and loads template metadata.
|
|
150
|
-
|
|
151
|
-
##### `RenderTemplate(templateEntity: TemplateEntityExtended, templateContent: TemplateContentEntity, data: any, SkipValidation?: boolean): Promise<TemplateRenderResult>`
|
|
152
|
-
|
|
153
|
-
Renders a template using metadata entities with optional validation.
|
|
154
|
-
|
|
155
|
-
##### `RenderTemplateSimple(templateText: string, data: any): Promise<TemplateRenderResult>`
|
|
156
|
-
|
|
157
|
-
Renders a template string without metadata integration.
|
|
158
|
-
|
|
159
|
-
##### `GetTemplateByName(templateName: string): TemplateEntityExtended | null`
|
|
160
|
-
|
|
161
|
-
Retrieves a template entity by its name.
|
|
162
|
-
|
|
163
|
-
##### `GetTemplateByID(templateID: string): TemplateEntityExtended | null`
|
|
164
|
-
|
|
165
|
-
Retrieves a template entity by its ID.
|
|
166
|
-
|
|
167
|
-
##### `ClearTemplateCache(): void`
|
|
168
|
-
|
|
169
|
-
Clears the internal template cache.
|
|
88
|
+
### Simple Template Rendering
|
|
170
89
|
|
|
171
|
-
|
|
90
|
+
For ad-hoc templates not stored in the database:
|
|
172
91
|
|
|
173
92
|
```typescript
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
```
|
|
180
|
-
|
|
181
|
-
### Built-in Filters
|
|
182
|
-
|
|
183
|
-
The template engine provides several filters for handling complex objects and JSON data:
|
|
184
|
-
|
|
185
|
-
#### `dump` (Nunjucks built-in)
|
|
186
|
-
Converts any JavaScript object to a formatted JSON string.
|
|
187
|
-
|
|
188
|
-
```nunjucks
|
|
189
|
-
{{ myObject | dump }} <!-- Pretty-printed with 2 spaces -->
|
|
190
|
-
{{ myObject | dump(4) }} <!-- Pretty-printed with 4 spaces -->
|
|
191
|
-
{{ myObject | dump(0) }} <!-- Compact single-line format -->
|
|
192
|
-
```
|
|
193
|
-
|
|
194
|
-
#### `json` (Custom filter)
|
|
195
|
-
Similar to `dump` but with better error handling. Converts objects to JSON strings.
|
|
196
|
-
|
|
197
|
-
```nunjucks
|
|
198
|
-
{{ userData | json }} <!-- Pretty-printed with 2 spaces (default) -->
|
|
199
|
-
{{ userData | json(4) }} <!-- Pretty-printed with 4 spaces -->
|
|
200
|
-
{{ userData | json(0) }} <!-- Compact format -->
|
|
93
|
+
const result = await engine.RenderTemplateSimple(
|
|
94
|
+
'Hello {{ name }}, welcome to {{ company }}!',
|
|
95
|
+
{ name: 'Jane', company: 'MemberJunction' }
|
|
96
|
+
);
|
|
97
|
+
// result.Output: "Hello Jane, welcome to MemberJunction!"
|
|
201
98
|
```
|
|
202
99
|
|
|
203
|
-
|
|
100
|
+
### Custom Nunjucks Filters
|
|
204
101
|
|
|
205
|
-
|
|
206
|
-
Converts objects to compact JSON strings (no formatting).
|
|
102
|
+
The engine provides built-in filters for JSON operations:
|
|
207
103
|
|
|
208
104
|
```nunjucks
|
|
209
|
-
{
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
#### `jsonparse` (Custom filter)
|
|
213
|
-
Parses JSON strings into JavaScript objects. Useful for processing JSON data stored as strings.
|
|
214
|
-
|
|
215
|
-
```nunjucks
|
|
216
|
-
{{ '{"name":"John","age":30}' | jsonparse | json }}
|
|
217
|
-
<!-- First parses the string to object, then formats it -->
|
|
218
|
-
|
|
219
|
-
<!-- Access parsed object properties -->
|
|
220
|
-
{{ '{"name":"John","age":30}' | jsonparse | attr("name") }}
|
|
221
|
-
<!-- Output: John -->
|
|
222
|
-
```
|
|
105
|
+
{# Convert object to formatted JSON #}
|
|
106
|
+
{{ userData | json }}
|
|
223
107
|
|
|
224
|
-
|
|
108
|
+
{# Compact JSON output #}
|
|
109
|
+
{{ userData | jsoninline }}
|
|
225
110
|
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
```nunjucks
|
|
229
|
-
<!-- Problem: Shows [object Object] -->
|
|
230
|
-
<div>User Data: {{ userData }}</div>
|
|
231
|
-
|
|
232
|
-
<!-- Solutions: Use filters to display JSON -->
|
|
233
|
-
<div>User Data: {{ userData | dump }}</div>
|
|
234
|
-
<div>User Data: {{ userData | json }}</div>
|
|
235
|
-
<pre>{{ userData | json(2) }}</pre>
|
|
236
|
-
|
|
237
|
-
<!-- For debugging: Compact format -->
|
|
238
|
-
<script>
|
|
239
|
-
const data = {{ userData | jsoninline | safe }};
|
|
240
|
-
</script>
|
|
111
|
+
{# Parse a JSON string back to object #}
|
|
112
|
+
{% set parsed = jsonString | jsonparse %}
|
|
241
113
|
```
|
|
242
114
|
|
|
243
|
-
|
|
115
|
+
### Template Extensions
|
|
244
116
|
|
|
245
|
-
|
|
246
|
-
<!-- Parse a JSON string, then format it nicely -->
|
|
247
|
-
{{ jsonString | jsonparse | json(4) }}
|
|
117
|
+
Extensions are registered via the MJ class factory:
|
|
248
118
|
|
|
249
|
-
|
|
250
|
-
|
|
119
|
+
```mermaid
|
|
120
|
+
graph LR
|
|
121
|
+
A[TemplateExtensionBase] --> B[AIPrompt Extension]
|
|
122
|
+
A --> C[TemplateEmbed Extension]
|
|
123
|
+
A --> D[Custom Extensions]
|
|
251
124
|
|
|
252
|
-
|
|
253
|
-
|
|
125
|
+
style A fill:#2d6a9f,stroke:#1a4971,color:#fff
|
|
126
|
+
style B fill:#2d8659,stroke:#1a5c3a,color:#fff
|
|
127
|
+
style C fill:#2d8659,stroke:#1a5c3a,color:#fff
|
|
128
|
+
style D fill:#7c5295,stroke:#563a6b,color:#fff
|
|
254
129
|
```
|
|
255
130
|
|
|
256
|
-
|
|
131
|
+
- **AIPrompt Extension**: Executes AI prompts inline within templates using `{% aiprompt %}` tags
|
|
132
|
+
- **TemplateEmbed Extension**: Embeds other templates within a template using `{% templateembed %}` tags
|
|
257
133
|
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
- `AIModel` (optional): Specific AI model to use (e.g., "gpt-4", "claude-3")
|
|
261
|
-
- `AllowFormatting` (optional): Whether to allow formatted output (HTML, Markdown, etc.)
|
|
262
|
-
|
|
263
|
-
#### Template Embed Extension Parameters
|
|
134
|
+
## API Reference
|
|
264
135
|
|
|
265
|
-
|
|
266
|
-
- `type` (optional): Specific content type to use
|
|
267
|
-
- `data` (optional): Additional data to pass to the embedded template
|
|
136
|
+
### TemplateEngineServer
|
|
268
137
|
|
|
269
|
-
|
|
138
|
+
| Member | Type | Description |
|
|
139
|
+
|--------|------|-------------|
|
|
140
|
+
| `Instance` | static getter | Singleton instance |
|
|
141
|
+
| `Config()` | method | Load metadata and initialize Nunjucks environment |
|
|
142
|
+
| `RenderTemplate()` | method | Render a stored template with validation |
|
|
143
|
+
| `RenderTemplateSimple()` | method | Render an ad-hoc template string |
|
|
144
|
+
| `AddTemplate()` | method | Add a template to the Nunjucks loader |
|
|
145
|
+
| `SetupNunjucks()` | method | Re-initialize the Nunjucks environment |
|
|
146
|
+
| `ClearTemplateCache()` | method | Clear cached compiled templates |
|
|
270
147
|
|
|
271
|
-
|
|
148
|
+
### Rendering Process
|
|
272
149
|
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
constructor(contextUser: UserInfo) {
|
|
279
|
-
super(contextUser);
|
|
280
|
-
this.tags = ['myTag'];
|
|
281
|
-
}
|
|
282
|
-
|
|
283
|
-
public parse(parser: Parser, nodes: Nodes, lexer: Lexer) {
|
|
284
|
-
const tok = parser.nextToken();
|
|
285
|
-
const params = parser.parseSignature(null, true);
|
|
286
|
-
parser.advanceAfterBlockEnd(tok.value);
|
|
287
|
-
|
|
288
|
-
const body = parser.parseUntilBlocks('endMyTag');
|
|
289
|
-
parser.advanceAfterBlockEnd();
|
|
290
|
-
|
|
291
|
-
return new nodes.CallExtensionAsync(this, 'run', params, [body]);
|
|
292
|
-
}
|
|
293
|
-
|
|
294
|
-
public run(context: Context, params: any, body: any, callBack: NunjucksCallback) {
|
|
295
|
-
// Your extension logic here
|
|
296
|
-
try {
|
|
297
|
-
const content = body();
|
|
298
|
-
// Process content...
|
|
299
|
-
callBack(null, processedContent);
|
|
300
|
-
} catch (error) {
|
|
301
|
-
callBack(error);
|
|
302
|
-
}
|
|
303
|
-
}
|
|
304
|
-
}
|
|
305
|
-
```
|
|
150
|
+
1. **Validation**: Input data is validated against template parameter definitions
|
|
151
|
+
2. **Default Merging**: Missing parameters receive default values (content-specific defaults override global defaults)
|
|
152
|
+
3. **Compilation**: Template text is compiled by Nunjucks (cached after first compile)
|
|
153
|
+
4. **Rendering**: Nunjucks processes the template with merged data
|
|
154
|
+
5. **Result**: Returns `TemplateRenderResult` with `Success`, `Output`, and optional `Message`
|
|
306
155
|
|
|
307
156
|
## Dependencies
|
|
308
157
|
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
-
|
|
317
|
-
|
|
318
|
-
## Integration with MemberJunction
|
|
319
|
-
|
|
320
|
-
This package integrates seamlessly with other MemberJunction packages:
|
|
321
|
-
|
|
322
|
-
- **Entity System**: Templates are stored as entities with full metadata support
|
|
323
|
-
- **AI Engine**: Direct integration for AI-powered content generation
|
|
324
|
-
- **User Context**: Templates respect user permissions and context
|
|
325
|
-
- **Metadata Provider**: Flexible metadata loading strategies
|
|
326
|
-
|
|
327
|
-
## Configuration
|
|
328
|
-
|
|
329
|
-
The template engine uses the MemberJunction configuration system. Key configuration options:
|
|
330
|
-
|
|
331
|
-
- Template caching strategies
|
|
332
|
-
- Default AI models for prompts
|
|
333
|
-
- Extension registration
|
|
334
|
-
- Nunjucks environment settings
|
|
335
|
-
|
|
336
|
-
## Performance Considerations
|
|
337
|
-
|
|
338
|
-
- Templates are cached after first compilation
|
|
339
|
-
- Use `ClearTemplateCache()` when templates are updated
|
|
340
|
-
- AI prompts are processed asynchronously
|
|
341
|
-
- Template embedding includes cycle detection
|
|
342
|
-
|
|
343
|
-
## Error Handling
|
|
344
|
-
|
|
345
|
-
All rendering methods return a `TemplateRenderResult` object:
|
|
346
|
-
|
|
347
|
-
```typescript
|
|
348
|
-
const result = await templateEngine.RenderTemplateSimple(template, data);
|
|
349
|
-
|
|
350
|
-
if (!result.Success) {
|
|
351
|
-
console.error('Rendering failed:', result.Message);
|
|
352
|
-
// Handle error appropriately
|
|
353
|
-
} else {
|
|
354
|
-
// Use result.Output
|
|
355
|
-
}
|
|
356
|
-
```
|
|
357
|
-
|
|
358
|
-
## Best Practices
|
|
359
|
-
|
|
360
|
-
1. **Always check rendering results** for success before using output
|
|
361
|
-
2. **Configure the engine once** at application startup
|
|
362
|
-
3. **Use template validation** for user-provided data
|
|
363
|
-
4. **Clear cache** when templates are modified
|
|
364
|
-
5. **Handle AI failures gracefully** with fallback content
|
|
365
|
-
6. **Avoid deep template nesting** to prevent performance issues
|
|
158
|
+
| Package | Purpose |
|
|
159
|
+
|---------|---------|
|
|
160
|
+
| `@memberjunction/templates-base-types` | Base engine and result types |
|
|
161
|
+
| `@memberjunction/core` | UserInfo, logging utilities |
|
|
162
|
+
| `@memberjunction/core-entities` | Template entity types |
|
|
163
|
+
| `@memberjunction/global` | Class factory for extensions |
|
|
164
|
+
| `@memberjunction/ai` | AI integration for prompts |
|
|
165
|
+
| `@memberjunction/ai-core-plus` | AI core utilities |
|
|
166
|
+
| `nunjucks` | Template rendering engine |
|
|
366
167
|
|
|
367
168
|
## License
|
|
368
169
|
|
|
369
|
-
ISC
|
|
370
|
-
|
|
371
|
-
## Support
|
|
372
|
-
|
|
373
|
-
For issues, questions, or contributions, please visit [MemberJunction.com](https://memberjunction.com) or contact the development team.
|
|
170
|
+
ISC
|
package/dist/TemplateEngine.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { IMetadataProvider, UserInfo } from "@memberjunction/core";
|
|
2
2
|
import { TemplateContentEntity, TemplateEntityExtended } from "@memberjunction/core-entities";
|
|
3
|
-
import
|
|
3
|
+
import nunjucks from 'nunjucks';
|
|
4
4
|
import { TemplateRenderResult, TemplateEngineBase } from '@memberjunction/templates-base-types';
|
|
5
5
|
/**
|
|
6
6
|
* This class extends the nunjucks loader to allow adding templates directly to the loader
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TemplateEngine.d.ts","sourceRoot":"","sources":["../src/TemplateEngine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAY,QAAQ,EAAuB,MAAM,sBAAsB,CAAC;AAClG,OAAO,EAAE,qBAAqB,EAAE,sBAAsB,EAAuB,MAAM,+BAA+B,CAAC;AACnH,OAAO,
|
|
1
|
+
{"version":3,"file":"TemplateEngine.d.ts","sourceRoot":"","sources":["../src/TemplateEngine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAY,QAAQ,EAAuB,MAAM,sBAAsB,CAAC;AAClG,OAAO,EAAE,qBAAqB,EAAE,sBAAsB,EAAuB,MAAM,+BAA+B,CAAC;AACnH,OAAO,QAAQ,MAAM,UAAU,CAAC;AAGhC,OAAO,EAAE,oBAAoB,EAAE,kBAAkB,EAAE,MAAM,sCAAsC,CAAA;AAE/F;;GAEG;AACH,qBAAa,oBAAqB,SAAQ,QAAQ,CAAC,MAAM;IAC9C,KAAK,EAAE,IAAI,CAAC;IAEnB,OAAO,CAAC,SAAS,C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kB;IAIzB;;;;OAIG;cACa,mBAAmB,CAAC,QAAQ,EAAE,QAAQ,CAAC,QAAQ,EAAE,IAAI,EAAE,GAAG,GAAG,OAAO,CAAC,MAAM,CAAC;IAY5F;;;;;;;;;;;;;OAaG;IACH,SAAS,CAAC,kBAAkB,CAAC,cAAc,EAAE,sBAAsB,EAAE,SAAS,EAAE,MAAM,EAAE,IAAI,EAAE,GAAG,GAAG,GAAG;CAuD1G"}
|
package/dist/TemplateEngine.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { LogError } from "@memberjunction/core";
|
|
2
|
-
import
|
|
2
|
+
import nunjucks from 'nunjucks';
|
|
3
3
|
import { MJGlobal } from "@memberjunction/global";
|
|
4
4
|
import { TemplateExtensionBase } from "./extensions/TemplateExtensionBase.js";
|
|
5
5
|
import { TemplateEngineBase } from '@memberjunction/templates-base-types';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TemplateEngine.js","sourceRoot":"","sources":["../src/TemplateEngine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqB,QAAQ,EAAiC,MAAM,sBAAsB,CAAC;AAElG,OAAO,
|
|
1
|
+
{"version":3,"file":"TemplateEngine.js","sourceRoot":"","sources":["../src/TemplateEngine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqB,QAAQ,EAAiC,MAAM,sBAAsB,CAAC;AAElG,OAAO,QAAQ,MAAM,UAAU,CAAC;AAChC,OAAO,EAAE,QAAQ,EAAE,MAAM,wBAAwB,CAAC;AAClD,OAAO,EAAE,qBAAqB,EAAE,MAAM,oCAAoC,CAAC;AAC3E,OAAO,EAAwB,kBAAkB,EAAE,MAAM,sCAAsC,CAAA;AAE/F;;GAEG;AACH,MAAM,OAAO,oBAAqB,SAAQ,QAAQ,CAAC,MAAM;IAAzD;;QAGY,cAAS,GAAqD,EAAE,CAAC;IA2B7E,CAAC;IAzBG;;;;OAIG;IACI,WAAW,CAAC,UAAkB,EAAE,QAAgC;QACnE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CAAC,CAAC,KAAK,EAAE,IAAI,EAAE,EAAE;YACjC,8DAA8D;YAC9D,IAAI,UAAU,CAAC,IAAI,CAAC,KAAK,SAAS,IAAI,KAAK,CAAC,YAAY,KAAK,IAAI,IAAI,KAAK,CAAC,YAAY,KAAK,SAAS,EAAE,CAAC;gBACpG,IAAI,CAAC;oBACD,mCAAmC;oBACnC,QAAQ,KAAK,CAAC,IAAI,EAAE,CAAC;wBACjB,KAAK,OAAO,CAAC;wBACb,KAAK,QAAQ,CAAC;wBACd,KAAK,QAAQ,CAAC;wBACd,KAAK,QAAQ;4BACT,yCAAyC;4BACzC,IAAI,CAAC;gCACD,UAAU,CAAC,IAAI,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,YAAY,CAAC,CAAC;4BACtD,CAAC;4BAAC,MAAM,CAAC;gCACL,+BAA+B;gCAC/B,UAAU,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC,YAAY,CAAC;4BAC1C,CAAC;4BACD,MAAM;wBAEV,KAAK,QAAQ,CAAC;wBACd;4BACI,2CAA2C;4BAC3C,UAAU,CAAC,IAAI,CAAC,GAAG,KAAK,CAAC,YAAY,CAAC;4BACtC,MAAM;oBACd,CAAC;gBACL,CAAC;gBAAC,OAAO,KAAK,EAAE,CAAC;oBACb,0DAA0D;oBAC1D,QAAQ,CAAC,gDAAgD,IAAI,MAAM,KAAK,CAAC,OAAO,EAAE,CAAC,CAAC;gBACxF,CAAC;YACL,CAAC;QACL,CAAC,CAAC,CAAC;QAEH,OAAO,UAAU,CAAC;IACtB,CAAC;CACJ"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@memberjunction/templates",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "4.
|
|
4
|
+
"version": "4.1.0",
|
|
5
5
|
"description": "MemberJunction Templating Engine and Utilities - Used for any application that requires templating utility functionality. NOTE: this package does use Angular Universal for compilation but is not marked with the usual ng prefix because it is a server-side library and not used within Angular apps.",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
@@ -19,14 +19,14 @@
|
|
|
19
19
|
"typescript": "^5.9.3"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@memberjunction/core": "4.
|
|
23
|
-
"@memberjunction/templates-base-types": "4.
|
|
24
|
-
"@memberjunction/ai": "4.
|
|
25
|
-
"@memberjunction/ai-core-plus": "4.
|
|
26
|
-
"@memberjunction/aiengine": "4.
|
|
27
|
-
"@memberjunction/ai-provider-bundle": "4.
|
|
28
|
-
"@memberjunction/core-entities": "4.
|
|
29
|
-
"@memberjunction/global": "4.
|
|
22
|
+
"@memberjunction/core": "4.1.0",
|
|
23
|
+
"@memberjunction/templates-base-types": "4.1.0",
|
|
24
|
+
"@memberjunction/ai": "4.1.0",
|
|
25
|
+
"@memberjunction/ai-core-plus": "4.1.0",
|
|
26
|
+
"@memberjunction/aiengine": "4.1.0",
|
|
27
|
+
"@memberjunction/ai-provider-bundle": "4.1.0",
|
|
28
|
+
"@memberjunction/core-entities": "4.1.0",
|
|
29
|
+
"@memberjunction/global": "4.1.0",
|
|
30
30
|
"nunjucks": "3.2.4"
|
|
31
31
|
},
|
|
32
32
|
"repository": {
|