From d9761b77b8f35682890c6157cad7ef16d9b769e6 Mon Sep 17 00:00:00 2001 From: Nils Knappmeier Date: Sat, 14 Jan 2023 22:25:05 +0100 Subject: [PATCH 1/2] remove wrong statement about literal statements `"` and `'` are not allowed as literal segment. At best, they may be used as `LiteralExpression` as parameter for helpers, but a template like ``` {{'my id containing spaces'}} ``` just does not parse --- src/guide/expressions.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/guide/expressions.md b/src/guide/expressions.md index 91088b860..7eb89e4b7 100644 --- a/src/guide/expressions.md +++ b/src/guide/expressions.md @@ -88,8 +88,6 @@ In addition, the words `true`, `false`, `null` and `undefined` are only allowed To reference a property that is not a valid identifier, you can use segment-literal notation, `[`. You may not include a closing `]` in a path-literal, but all other characters are allowed. -JavaScript-style strings, `"` and `'`, may also be used instead of `[` pairs. - ## HTML-escaping From 870fd471759736d9eac62053d3e02cb4e76da7c7 Mon Sep 17 00:00:00 2001 From: Il Harper Date: Sun, 15 Jan 2023 10:26:37 +0800 Subject: [PATCH 2/2] docs: zh-CN translate sync for d9761b7 --- src/zh/guide/expressions.md | 2 -- 1 file changed, 2 deletions(-) diff --git a/src/zh/guide/expressions.md b/src/zh/guide/expressions.md index 4b24078ef..2fbc8492b 100644 --- a/src/zh/guide/expressions.md +++ b/src/zh/guide/expressions.md @@ -86,8 +86,6 @@ _Whitespace_ `!` `"` `#` `%` `&` `'` `(` `)` `*` `+` `,` `.` `/` `;` `<` `=` `>` 若想引用一个并非合法的标识符,你可以使用 `[`。在路径表达式中你不必使用 `]` 来关闭它,但其他表达式中是需要的。 -JavaScript 样式的字符串如 `"` 和 `'` 也可用于替代 `[`。 - ## HTML 转义