Harttle and Harttle
071368afe1
feat: use evalValue to parse & render expression, #527
2022-08-24 20:46:22 +08:00
Harttle
4289b4e804
refactor: rename toValue to toValueSync
2022-07-10 00:24:00 +08:00
Harttle and Harttle
6801552fe6
feat: customize globals & strictVariables when calling render, see #432
2021-12-11 20:22:58 +08:00
Harttle and Harttle
aebeae9e1b
fix: relative root (by default) yields LookupError, fixes #419 , #424 , also related to #395
2021-10-27 23:55:39 +08:00
Harttle
564972ba74
docs: add version info in playground.html
2021-10-20 23:20:23 +08:00
Harttle and harttle
b5b2a98d5e
chore: fix types
2021-10-16 22:36:46 +08:00
Harttle
822ba0be0f
fix: skip root check for renderFile()
2021-10-06 18:38:58 +08:00
Harttle
a3455ebd0b
feat: relativeReference for render/include/layout, #395
...
- `relativeReference` is enabled by default, set to `false` to disable
- Referenced files are still constrained within root/partias/layouts
- fix: relative filenames are not constrained (which allows arbitrary filesystem read)
Example Usage:
{% render "../foo/bar.html" %}
Note:
../foo/bar.html' should also be within `partials` (or `root` if `partials` not set)
2021-10-06 17:36:37 +08:00
harttle
68c4cfcfb6
feat: renderFileToNodeStream(filepath, scope)
2021-10-03 21:21:25 +08:00
harttle
b9ae479b65
feat: add layouts, partials apart from root, #395
2021-10-03 18:51:14 +08:00
Harttle and Jun Yang
9012133e07
feat: stream rendering, closed #361 fixes #360
2021-09-30 22:15:09 +08:00
harttle
24f5346084
perf: improve performance by 4x by simplified parseFile
...
- previously deprecated `getTemplate()` and `getTemplateSync()` not no longer supported
- `opts` no longer support dynamic set in `parseFile()`, `renderFile()` arguments
2021-09-27 23:04:41 +08:00
Laurin Quast and Jun Yang
4e394b9072
feat: export errors for better error handling in user-land
2021-05-01 19:06:33 +08:00
harttle
2f059f6a25
feat: support filters in if/unless/case, see #287
2021-02-12 22:22:41 +08:00
harttle
4e82da689e
fix: respect fs in parser options, for #233
2021-02-12 15:17:21 +08:00
Jason Etcovitch and Jun Yang
befc33c4eb
feat: create trie programmatically in options
2021-02-04 09:11:28 +08:00
Alex de Wergifosse and Jun Yang
cd92e77726
feat: add option for keeping variable type in output
2020-12-16 10:20:10 +08:00
harttle
f9f595f0f4
feat: passing liquid to FilterImpl, closes #277
2020-12-08 00:17:27 +08:00
harttle
2e5ab98bfc
feat: export toPromise and toValue, see #158
2020-08-05 00:46:01 +08:00
Martin Schuster and Jun Yang
a93f11d25a
fix: respect cache render options
2020-04-03 10:42:32 +08:00
harttle
02e6171e25
chore: fix types
2020-03-25 00:25:47 +08:00
harttle
479c63350a
fix: throws on invalid arguments for prepend/append, fixes #208
2020-03-24 23:57:26 +08:00
harttle
d2d6a38235
perf: introduce AST to avoid reparse
2020-03-15 02:51:25 +08:00
harttle
61dac49b04
feat: async cache.read()/write(), remove .has()
2020-03-05 01:47:53 +08:00
harttle
6ea6881f08
feat: with & for in render tag, closes #195
2020-03-04 07:08:54 +08:00
harttle
df8a919f71
feat: move filters/tags to instances, fixes #188
2020-03-03 00:02:29 +08:00
tgrandgent and Jun Yang
4b079c54b1
fix: add this to fs references in parseFile
2020-01-04 12:05:39 +08:00
harttle
2dd43559b5
feat: support require.resolve for lookup, see #168
2019-11-07 18:46:37 +08:00
Jun Yang
d5e7b047bb
feat: Support for the "render" tag #163
2019-10-27 00:06:16 +08:00
harttle
b82fa9ed2b
pref: remove await/async from internal async calls
2019-10-26 08:57:33 -05:00
harttle
6b83788077
feat: alias getTemplate() to parseFile()
...
* deprecate Liquid#getTemplate: use Liquid#parseFile instead
* deprecate Liquid#getTemplateSync: use Liquid#parseFileSync instead
2019-10-07 23:34:12 +08:00
harttle
0426d08fd0
style: fix linting
2019-08-26 10:15:43 -05:00
harttle
7fb01ad69a
feat: renderSync, parseAndRenderSync and renderFileSync, see #48
2019-08-26 10:15:43 -05:00
harttle
3b9fc7e6bf
perf: target to es6, fixes #137
...
BREAKING CHANGE: ship to Node.js 8, the dist/liquid.cjs.js (main) nolonger
supports Node.js 6, other bundles are also provided via dist/liquid.esm.js, dist/liquid.js (ES5 umd) and liquid.min.js (minified ES5 umd)
2019-08-26 10:15:43 -05:00
harttle
ae45c4622e
fix: break/continue omitting output before them, #123
...
BREAKING CHANGE: remove default export, now should be used like import
{Liquid} from 'liquidjs'
2019-08-26 10:15:43 -05:00
harttle
88c89fe3b3
style: introduce @typescript-eslint/recommended
2019-07-06 14:33:34 +08:00
Jun Yang
96c061bee0
style: remove semi
2019-06-27 09:32:51 +08:00
Patrick Malouin and Jun Yang
edb2cc1f37
Expose fs as an option to override the default implementations
2019-06-27 09:25:17 +08:00
Patrick Malouin and Jun Yang
1ffba2bc76
perf: improve getTemplate() when cache is enabled
...
Checking for file existence is unnecessary when cache contains entry.
2019-06-17 11:01:02 +08:00
harttle
00bc1efe6a
feat: pass context to filters
2019-04-17 10:24:55 +08:00
harttle
45e3c2bb8e
refactor: switch Context <-> Scope concepts
2019-03-25 10:36:23 +08:00
harttle
5ffc904f80
fix: named params for filters, working on #113
2019-03-06 01:30:47 +08:00
harttle
7bee9fc92d
feat: exported Drop interface for #107
...
Deprecate snake_cased options and APIs, sed #109
2019-02-28 00:05:08 +08:00
harttle
53a835ab54
fix( #108 ): remove absolute path in emitted d.ts
2019-02-26 00:43:30 +08:00
harttle
3cf01603e8
chore: fix linting
2019-02-23 03:50:45 +08:00
harttle
5b6100d12b
refactor: strictly typed
2019-02-23 00:49:54 +08:00
harttle
3dbab238ae
BREAKING CHANGE: trim_value_* -> trim_output_*
2019-02-21 01:07:32 +08:00
harttle
852c6ad453
refactor: remove mock-fs from dev dependency
2019-02-19 22:28:27 +08:00
harttle
fc9ebdb90f
chore(TypeScript): fix linting and generate .d.ts
2019-02-17 18:20:04 +08:00
harttle
7ee87008c7
chore(TypeScript): demo for typescript
2019-02-17 14:22:13 +08:00