aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--packages/astro/templates/actions.mjs5
-rw-r--r--packages/astro/test/actions.test.js2
2 files changed, 4 insertions, 3 deletions
diff --git a/packages/astro/templates/actions.mjs b/packages/astro/templates/actions.mjs
index 43a1829fd..349693eba 100644
--- a/packages/astro/templates/actions.mjs
+++ b/packages/astro/templates/actions.mjs
@@ -5,7 +5,7 @@ import {
getActionQueryString,
} from 'astro:actions';
-const ENCODED_DOT = "%2E";
+const ENCODED_DOT = '%2E';
function toActionProxy(actionCallback = {}, aggregatedPath = '') {
return new Proxy(actionCallback, {
@@ -14,7 +14,8 @@ function toActionProxy(actionCallback = {}, aggregatedPath = '') {
return target[objKey];
}
// Add the key, encoding dots so they're not interpreted as nested properties.
- const path = aggregatedPath + encodeURIComponent(objKey.toString()).replaceAll('.', ENCODED_DOT);
+ const path =
+ aggregatedPath + encodeURIComponent(objKey.toString()).replaceAll('.', ENCODED_DOT);
function action(param) {
return handleAction(param, path, this);
}
diff --git a/packages/astro/test/actions.test.js b/packages/astro/test/actions.test.js
index 70c6d1036..793e6ebe7 100644
--- a/packages/astro/test/actions.test.js
+++ b/packages/astro/test/actions.test.js
@@ -131,7 +131,7 @@ describe('Astro Actions', () => {
const data = devalue.parse(text);
assert.equal(data, 'Hello, ben!');
}
- })
+ });
});
describe('build', () => {