Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

template-fragments #1441

Open
johntom opened this issue Jun 11, 2023 · 2 comments
Open

template-fragments #1441

johntom opened this issue Jun 11, 2023 · 2 comments

Comments

@johntom
Copy link

johntom commented Jun 11, 2023

Hi,
I've been using htmx and they have a section in docs called https://htmx.org/essays/template-fragments/. I then found out that fragments are supported in Apostroph 3 (https://v3.docs.apostrophecms.org/guide/fragments.html#using-fragments) which uses numjucks as its template engine and I'm curious if ...

  1. Are they using fragments in the same way as jinja2?
  2. Do you plan to support template-fragments in a future release?
    Very happy user using fastify/nunjucks and htmx.
    TIA
    John
@NextThread
Copy link

hey, can I work on this issue

@webketje
Copy link

webketje commented Nov 2, 2023

I think this should not be in core. It is a requirement specific to the usage of a third-party software implementing server-driven partial hydration of front-end views, a concern that is not in scope of the Nunjucks templating library. For all other flows and purposes, asynchronous data should be loaded prior to a synchronous Nunjucks render call, or should use an asynchronous custom loader together with an async Nunjucks render call

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants