Implicit layout value with Express #844
malaudha
started this conversation in
Working with Express
Replies: 1 comment
-
|
Try set a custom fs instance and change the file content when returning to Liquid parser. See https://liquidjs.com/tutorials/render-file.html#Abstract-File-System |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I'm trying to declare a default layout for each of the visited URLs on my local Express server but can't get it to work. I've tried using several methods and parse the template literal with the
{% layout "xx" %}but I never manage to have elements called within the parsed templates to resolve. For instance, parsing a filebuttons.htmlwith this content:{% render 'partials/elements/button' %}fails because it never resolves this path, but when using static HTML code, it works.I have to admit I have trouble getting my way through the documentation of the methods of the api, so I might have tried random things, but anyone has an idea on how to achieve this?
PS: I am already able to make this work with the
{% layout "xx" %}in the template itself, but the whole point is to avoid having to repeat that in every file.Beta Was this translation helpful? Give feedback.
All reactions