"@[handle]" convention collides with Handlebars' special "@partial-block"
See original GitHub issueFrom Handlebars’ docs:
[Block] syntax may also be used to pass templates to the partial, which can be executed by the specially named partial, @partial-block.
It seems that inside of Fractal, that doesn’t work…I’m assuming that’s because Fractal’s sucking up any partials with a name prefixed by @
.
This isn’t a show-stopper—you can accomplish the same thing with “inline partials”—but I figure it should at least be documented, especially since the @[handles]
stuff can’t be turned off (as the rest of the handlebars helpers can).
Issue Analytics
- State:
- Created 7 years ago
- Reactions:1
- Comments:12 (6 by maintainers)
Top Results From Across the Web
Partials
Handlebars allows for template reuse through partials. ... which can be executed by the specially named partial, @partial-block .
Read more >Handlebars Dynamic Partial Block
handlebars . This helper is called getPartialForTemplate . This is fine, but when I need to use the resolved template as a block...
Read more >Handlebars syntax
Typographical Conventions. Item, Description. {{ }}, Handlebars double-braces will URL encode characters that are able to be URL encoded.
Read more >The hidden power of Handlebars partials
I was recently working on a small project with only a handful of static pages. Because it was small, we started without a...
Read more >14 Handlebars training: Partials - YouTube
In the last video of my Handlebars training course, we explore the last topic - Partial Templates - or partials as they're commonly...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi @nategreen, this error seems to be due to a change in how handlebars handles
@partial-block
s, which now makes theif
trick unnecessary. I’ve corrected the error in my own templates using the block syntax which they describe in their docs - along the lines of@nategreen I’ve successfully used
@partial-block
within Fractal, but there’s a small caveat. I wrote about it here: https://clearleft.com/posts/417 - see Container Components.