diff --git a/javascript-modules/engines/eleventy-engine/lib/engine.js b/javascript-modules/engines/eleventy-engine/lib/engine.js
index 151585e3..7e25622d 100644
--- a/javascript-modules/engines/eleventy-engine/lib/engine.js
+++ b/javascript-modules/engines/eleventy-engine/lib/engine.js
@@ -175,7 +175,7 @@ export class Engine {
this.files[component_key] = [
`
`,
`Failed to render ${deepest_errored_component[1]}.
`,
- `
`,
+ ``,
`${error_string.replace(/, '<')}
`,
`
`
].join('\n');
diff --git a/javascript-modules/engines/hugo-engine/lib/engine.js b/javascript-modules/engines/hugo-engine/lib/engine.js
index 6fb77693..2dae53db 100644
--- a/javascript-modules/engines/hugo-engine/lib/engine.js
+++ b/javascript-modules/engines/hugo-engine/lib/engine.js
@@ -217,7 +217,7 @@ export class Engine {
[deepest_errored_component]: [
``,
`Failed to render ${deepest_errored_component}.
`,
- `
`,
+ ``,
`${error_msg.replace(/, '<')}
`,
`
`
].join('\n')
@@ -227,7 +227,10 @@ export class Engine {
const error_logs = log_messages.filter(log => log.startsWith("ERROR")).join("\n");
const missing_regex = /Component "([^"]+)" does not exist/ig;
- file_stack = [...error_logs.matchAll(missing_regex)].map(([, file]) => `layouts/partials/bookshop/components/${file}/${file}.hugo.html`);
+ file_stack = [...error_logs.matchAll(missing_regex)].map(([, file]) => {
+ let filename = file.split('/').pop();
+ return `layouts/partials/bookshop/components/${file}/${filename}.hugo.html`;
+ });
if (file_stack.length) {
const deepest_errored_component = file_stack[file_stack.length-1];
window.writeHugoFiles(JSON.stringify({
diff --git a/javascript-modules/engines/jekyll-engine/lib/engine.js b/javascript-modules/engines/jekyll-engine/lib/engine.js
index 173406e4..2d1d2228 100644
--- a/javascript-modules/engines/jekyll-engine/lib/engine.js
+++ b/javascript-modules/engines/jekyll-engine/lib/engine.js
@@ -181,7 +181,7 @@ export class Engine {
this.files[component_key] = [
``,
`Failed to render ${deepest_errored_component[1]}.
`,
- `
`,
+ ``,
`${error_string.replace(/, '<')}
`,
`
`
].join('\n');
diff --git a/javascript-modules/integration-tests/features/eleventy/live_editing/eleventy_bookshop_live_errors.feature b/javascript-modules/integration-tests/features/eleventy/live_editing/eleventy_bookshop_live_errors.feature
index e823c96f..97dacaaf 100644
--- a/javascript-modules/integration-tests/features/eleventy/live_editing/eleventy_bookshop_live_errors.feature
+++ b/javascript-modules/integration-tests/features/eleventy/live_editing/eleventy_bookshop_live_errors.feature
@@ -66,14 +66,14 @@ Feature: Eleventy Bookshop CloudCannon Live Editing Error Boundaries
* 🌐 The selector h1:nth-of-type(2) should contain "Hello World 02"
Scenario: Bookshop replaces non-existent components in an error boundary
- # Note: No `bad.eleventy.liquid` component has been created.
+ # Note: No `really/bad` component has been created.
Given 🌐 I have loaded my site in CloudCannon
When 🌐 CloudCannon pushes new yaml:
"""
components:
- _bookshop_name: good
text: Hello World 01
- - _bookshop_name: bad
+ - _bookshop_name: really/bad
- _bookshop_name: good
text: Hello World 02
"""
diff --git a/javascript-modules/integration-tests/features/hugo/live_editing/hugo_bookshop_live_errors.feature b/javascript-modules/integration-tests/features/hugo/live_editing/hugo_bookshop_live_errors.feature
index eac065ca..b1d0afa0 100644
--- a/javascript-modules/integration-tests/features/hugo/live_editing/hugo_bookshop_live_errors.feature
+++ b/javascript-modules/integration-tests/features/hugo/live_editing/hugo_bookshop_live_errors.feature
@@ -71,14 +71,14 @@ Feature: Hugo Bookshop CloudCannon Live Editing Error Boundaries
* 🌐 The selector h1:nth-of-type(2) should contain "Hello World 02"
Scenario: Bookshop replaces non-existent components in an error boundary
- # Note: No `bad.hugo.html` component has been created.
+ # Note: No `really/bad` component has been created.
Given 🌐 I have loaded my site in CloudCannon
When 🌐 CloudCannon pushes new yaml:
"""
components:
- _bookshop_name: good
text: Hello World 01
- - _bookshop_name: bad
+ - _bookshop_name: really/bad
- _bookshop_name: good
text: Hello World 02
"""
diff --git a/javascript-modules/integration-tests/features/jekyll/live_editing/jekyll_bookshop_live_errors.feature b/javascript-modules/integration-tests/features/jekyll/live_editing/jekyll_bookshop_live_errors.feature
index 16377d00..eecd6b22 100644
--- a/javascript-modules/integration-tests/features/jekyll/live_editing/jekyll_bookshop_live_errors.feature
+++ b/javascript-modules/integration-tests/features/jekyll/live_editing/jekyll_bookshop_live_errors.feature
@@ -65,14 +65,14 @@ Feature: Jekyll Bookshop CloudCannon Live Editing Error Boundaries
* 🌐 The selector h1:nth-of-type(2) should contain "Hello World 02"
Scenario: Bookshop replaces non-existent components in an error boundary
- # Note: No `bad.jekyll.html` component has been created.
+ # Note: No `really/bad` component has been created.
Given 🌐 I have loaded my site in CloudCannon
When 🌐 CloudCannon pushes new yaml:
"""
components:
- _bookshop_name: good
text: Hello World 01
- - _bookshop_name: bad
+ - _bookshop_name: really/bad
- _bookshop_name: good
text: Hello World 02
"""