[ci] format

This commit is contained in:
matthewp 2022-04-07 17:23:16 +00:00 committed by GitHub Actions
parent 8c04ff1f0b
commit c757427fca
2 changed files with 10 additions and 8 deletions

View file

@ -45,14 +45,16 @@ const _args = ${adapter.args ? JSON.stringify(adapter.args) : 'undefined'};
${ ${
adapter.exports adapter.exports
? `const _exports = adapter.createExports(_manifest, _args); ? `const _exports = adapter.createExports(_manifest, _args);
${adapter.exports.map((name) => { ${adapter.exports
if(name === 'default') { .map((name) => {
return `const _default = _exports['default']; if (name === 'default') {
return `const _default = _exports['default'];
export { _default as default };`; export { _default as default };`;
} else { } else {
return `export const ${name} = _exports['${name}'];` return `export const ${name} = _exports['${name}'];`;
} }
}).join('\n')} })
.join('\n')}
` `
: '' : ''
} }

View file

@ -30,5 +30,5 @@ export const createExports = (manifest: SSRManifest) => {
await setResponse(res, await app.render(request)); await setResponse(res, await app.render(request));
}; };
return { 'default': handler }; return { default: handler };
}; };