Skip to content

Commit

Permalink
[ci] format
Browse files Browse the repository at this point in the history
  • Loading branch information
matthewp authored and actions-user committed Apr 7, 2022
1 parent 8c04ff1 commit c757427
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 8 deletions.
16 changes: 9 additions & 7 deletions packages/astro/src/core/build/vite-plugin-ssr.ts
Original file line number Diff line number Diff line change
Expand Up @@ -45,14 +45,16 @@ const _args = ${adapter.args ? JSON.stringify(adapter.args) : 'undefined'};
${
adapter.exports
? `const _exports = adapter.createExports(_manifest, _args);
${adapter.exports.map((name) => {
if(name === 'default') {
return `const _default = _exports['default'];
${adapter.exports
.map((name) => {
if (name === 'default') {
return `const _default = _exports['default'];
export { _default as default };`;
} else {
return `export const ${name} = _exports['${name}'];`
}
}).join('\n')}
} else {
return `export const ${name} = _exports['${name}'];`;
}
})
.join('\n')}
`
: ''
}
Expand Down
2 changes: 1 addition & 1 deletion packages/integrations/vercel/src/server-entrypoint.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,5 @@ export const createExports = (manifest: SSRManifest) => {
await setResponse(res, await app.render(request));
};

return { 'default': handler };
return { default: handler };
};

0 comments on commit c757427

Please sign in to comment.