Skip to content

Commit b34e60a

Browse files
Update template-tag-format.md
1 parent 4d9154e commit b34e60a

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

guides/release/components/template-tag-format.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -298,6 +298,14 @@ class Example extends Component {
298298

299299
If in an environment with compilation, omitting the `/runtime` at the end of the import allows ahead-of-time compilation to occur on components created with `template()` for better runtime performance.
300300

301+
Without specifying `/runtime`, there are additional restrictions required for the argument passed to `template()`:
302+
- it must be a string literal
303+
304+
With the `/runtime`, the argument passed to `template()` can be an extpression, for example:
305+
```js
306+
/* someValue could be f rom anywhere */
307+
export default default template(someValue);
308+
```
301309

302310
## Testing
303311

0 commit comments

Comments
 (0)