You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Including njk files with the {% include 'file' %} shortcode inside a eleventy edge function (so inside a {% edge %} shortcode) makes the netlify-cli crash and return those errors:
◈ Reloaded edge function eleventy-edge
ERROR {
e: (unknown path)
Template render error: (unknown path)
TypeError: Cannot read properties of undefined (reading 'length'), file:liquid, line:26, col:13
24| Include in Edge:
25|
>> 26| {% endraw %}{% renderTemplate "njk,md" %}EleventyEdgeNunjucksPrecompile:ff52dcc677df32747974b84753251a34758479e15b80a2e93bdab560ef24568a{% endrenderTemplate %}{% raw %}
27|
28| </main>
29|
RenderError: (unknown path)
Template render error: (unknown path)
TypeError: Cannot read properties of undefined (reading 'length'), file:liquid, line:26, col:13
at RenderError2.LiquidError2 [as constructor] (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:32252:28)
at new RenderError2 (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:32290:28)
at Render2.<anonymous> (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:35440:49)
at step (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:31244:23)
at Object.throw (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:31191:18)
at https://cdn.11ty.dev/[email protected]/eleventy-edge.js:33814:32
at step (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:31244:23)
at Object.throw (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:31191:18)
at rejected (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:31169:36)
at Object.runMicrotasks (deno:core/01_core.js:297:30)
From Template render error: (unknown path)
Template render error: (unknown path)
TypeError: Cannot read properties of undefined (reading 'length')
at Object._prettifyError (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:24601:15)
at https://cdn.11ty.dev/[email protected]/eleventy-edge.js:29678:24
at file:///Users/tixie/Sources/demo-11ty-edge-include/netlify/edge-functions/_generated/eleventy-edge-app.js:64:11
at https://cdn.11ty.dev/[email protected]/eleventy-edge.js:29293:9
at RawTask.call (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:24964:19)
at flush (https://cdn.11ty.dev/[email protected]/eleventy-edge.js:24902:29)
at processTicksAndRejections (https://deno.land/[email protected]/node/_next_tick.ts:51:13)
}
If not already, load the dev server's page (usually at http://localhost:8888)
The error should be displayed on your terminal
Expected behavior
Display the included file without error
My dev environment
OS and Version: macOS 12.6
Eleventy Version: 2.0.0-canary.15
Additional context
There is this similar issue who have been closed without a solution since it wasn't easy to reproduce. I hope this one will with the help of the demo repo.
The text was updated successfully, but these errors were encountered:
Per the Eleventy Community Survey results and our refocus and prioritization towards our roots as a static site generator, we’re going to be deprecating Edge in 3.0 and closing issues related to the Edge plugin. I’m very sorry to have to do this—but unfortunately this was a necessary decision to allow the project to continue forward.
Describe the bug
Including njk files with the
{% include 'file' %}
shortcode inside a eleventy edge function (so inside a{% edge %}
shortcode) makes the netlify-cli crash and return those errors:To Reproduce
Steps to reproduce the behavior:
npm i
+npm run dev
http://localhost:8888
)Expected behavior
Display the included file without error
My dev environment
Additional context
There is this similar issue who have been closed without a solution since it wasn't easy to reproduce. I hope this one will with the help of the demo repo.
The text was updated successfully, but these errors were encountered: