Skip to content

Commit 49a2461

Browse files
committed
update release notes
1 parent e461e36 commit 49a2461

2 files changed

Lines changed: 55 additions & 1 deletion

File tree

app/views/pages/developer-guide/platformos-workflow/directory-structure/config.liquid

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ metadata:
2525
|safe_translate |true|If disabled, the `translate` filter (`t` is an alias for it) will mark the output as html_safe. This can lead to XSS vulnerability, if you provide user input as a variable, as it could contain malicious JavaScript. In such scenario, you should explicitly use another filter, `translate_escape` (or `t_escape`). However, by keeping this flag as `true`, the system will automatically use the equivalent of `t_escape` if you provide any variable to the translation key, making your application safer by default. We highly recommend keeping this flag to `true`.|
2626
|skip_elasticsearch |false|If you do not use the `keyword` argument in `records`/`users` queries or `customizations`/`people` queries, you can increase performance by avoiding indexing data in the ELasticSearch by setting this flag to `true`.|
2727
|slug_exact_match |true|If disabled, a page with slug `abc` will match not only `example.com/abc`, but also URLs like `example.com/abc/1`, `example.com/abc/1/x` and to control this behavior, you would need to set [max_deep_level Page property](/developer-guide/pages/pages#available-properties). By keeping this flag as true, only `example.com/abc` will be matched. Additionally, you will be able to use named parameters in the URLss, like /abc/:id. We highly recommend setting this flag to true.|
28+
|string_interpolation |false|When enabled, allows using {% raw %}`{{ }}`{% endraw %} syntax inside double-quoted strings for variable interpolation (e.g., {% raw %}`{% assign greeting = "Hello {{ name }}!" %}`{% endraw %}). This provides a more readable alternative to filter chains. **Note:** Enabling this is a breaking change if you have existing templates with double-quoted strings containing literal {% raw %}`{{ }}`{% endraw %} text - use single quotes for literals instead. We recommend enabling this for new projects.|
2829
|sync_assets |false|If enabled, with each deploy we will ensure that the state of `admin_assets` matches assets that were listed in the asset manifest, that is generated by pos-cli during pos-cli deploy.
2930
|sync_translations |false|If enabled, translations will be synchronized on each sync/deploy similarly to other resources, meaning if you remove a translation form a translation file and sync it, it will disappear from the Instance. It will also remove all translations from the deleted file. The default behaviour (for backwards compatibility) is that translations will not be deleted; in order to delete a translation one needs to explicitly call `admin_translation_unset` GraphQL mutation. This setting is compatible with `modules_that_allow_delete_on_deploy`.
3031
|translation_keys_to_ignore |[]|Allows to list translation keys which will not be updated/delete on sync/deploy. It is most useful if you would like to change translations using UI and will not reflect it in your codebase. Translations will still be created if not defined.
@@ -46,6 +47,7 @@ require_table_for_record_delete_mutation: true
4647
safe_translate: true
4748
skip_elasticsearch: true
4849
slug_exact_match: true
50+
string_interpolation: true
4951
sync_assets: true
5052
sync_translations: true
5153
websockets_require_csrf_token: true

app/views/pages/release-notes/unreleased.liquid

Lines changed: 53 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,13 +9,65 @@ metadata:
99

1010
#### {{ page.metadata.description }}
1111

12-
<!--<h4 class="release-note release-note__new">NEW</h4>-->
12+
<h4 class="release-note release-note__new">NEW</h4>
13+
14+
* **String interpolation in double-quoted strings**: You can now use `{{ }}` syntax inside double-quoted strings for cleaner, more readable variable interpolation. This feature is **disabled by default on existing instances** to prevent backwards compatibility issues, but **enabled by default on new instances**. To enable on an existing instance, add to your `config.yml`: `string_interpolation: true`
15+
16+
**Example:**
17+
```liquid
18+
{% raw %}
19+
{% assign name = "Alice" %}
20+
{% assign greeting = "Hello {{ name | upcase }}!" %}
21+
{{ greeting }}
22+
{% endraw %}
23+
```
24+
**Output:** `Hello ALICE!`
25+
26+
**Features:**
27+
* Works with variables, property access, array access, and filters
28+
* Supports filter chains: {% raw %}`"{{ name | upcase | truncate: 10 }}"`{% endraw %}
29+
* Multiple interpolations: {% raw %}`"{{ first }} {{ last }}"`{% endraw %}
30+
* Works in all tags that accept string values (assign, function, background, export, log, etc.):
31+
```liquid
32+
{% raw %}
33+
{% assign var = "world" %}
34+
{% log "hello {{ var }}" %}
35+
{% assign greeting = "hello {{ var }}" %}
36+
{% function res = "lib/func", arg: "hello {{ var }}" %}
37+
{% endraw %}
38+
```
39+
40+
**Important notes:**
41+
* Single-quoted strings never interpolate (use for literal `{{ }}` text)
42+
* **Breaking change if enabled:** Existing templates with double-quoted strings containing literal {% raw %}`{{ }}`{% endraw %} text will now interpolate. Use single quotes for literal text: {% raw %}`'Use {{ variable }} syntax'`{% endraw %}
1343

1444
<h4 class="release-note release-note__improved">IMPROVED</h4>
1545

1646
* **Upgraded internal dependencies** for improved performance and security
47+
* **Upgraded GraphQL gem to the latest version** for security and performance
1748
* **Clearer error messages for `record_update` and `record_destroy`**: When a record with the provided ID cannot be found, the error message now clearly specifies which table was being searched. For example:
1849
* Before: `Couldn't find Customization with 'id'=123`
1950
* After: `Can't find Boats with id=123`
51+
* **`assign` tag now supports hash/array operations directly**: The `assign` tag has been extended with capabilities previously only available through `hash_assign` (which is now deprecated). You can now use a single, unified syntax for all variable assignments, including initializing hash and array:
52+
* **Empty hash/array literals**: {% raw %}`{% assign foo = {} %}`, `{% assign bar = [] %}`{% endraw %} (no need to do {% raw %}`'{}' | parse_json`{% endraw %} anymore)
53+
* **Inline hash/array literals with values**: You can now create hashes and arrays with initial values directly in the assign tag. Variables are evaluated, and can be used both as values and as keys:
54+
```liquid
55+
{% raw %}
56+
{% assign var = "hello" %}
57+
{% assign hash = { "key": var, var: "value", arr: ["el1", var] } %}
58+
{{ hash }}
59+
{% endraw %}
60+
```
61+
**Output:** `{ "key": "hello", "hello": "value", "arr": ["el1", "hello"] }`
62+
* **Bracket notation**: {% raw %}`{% assign foo["bar"] = "baz" %}`{% endraw %}
63+
* **Dot notation**: {% raw %}`{% assign foo.bar = "baz" %}`{% endraw %}
64+
* **Mixed notation** (combining dots and brackets): {% raw %}`{% assign foo.bar["baz"] = "qux" %}`{% endraw %}
65+
* **Array append with `<<`**: {% raw %}`{% assign foo << 'bar' %}`{% endraw %} (no need to use `array_add` filter)
66+
* **Nested operations**: Full support for deeply nested hash and array assignments, e.g., {% raw %}`{% assign foo["bar"]["baz"]["qux"] = [] %}{% assign foo["bar"]["baz"]["qux"] << "first" %}`{% endraw %}
67+
* **Performance**: Key lookups are pre-computed at parse time for faster rendering
68+
* **`function` tag now supports the same hash/array syntax**: Bracket notation, dot notation, mixed notation, and array append with `<<` now work with `function` too:
69+
* {% raw %}`{% function foo["bar"] = 'partials/compute', input: 'baz' %}`{% endraw %}
70+
* {% raw %}`{% function foo.bar["baz"] = 'partials/get_name', id: 123 %}`{% endraw %}
71+
* {% raw %}`{% function foo << 'partials/fetch_item', id: 1 %}`{% endraw %}
2072

2173
<!-- <h4 class="release-note release-note__fixed">FIXED</h4> -->

0 commit comments

Comments
 (0)