[ci] yarn format

This commit is contained in:
tony-sull 2022-02-15 17:48:39 +00:00 committed by GitHub Actions
parent d6d35bcafc
commit 160c41403b
4 changed files with 2 additions and 4 deletions

View file

@ -314,7 +314,6 @@ export interface EndpointHandler {
[method: string]: (params: any) => EndpointOutput;
}
/**
* Astro Renderer
* Docs: https://docs.astro.build/reference/renderer-reference/

View file

@ -487,7 +487,7 @@ function getOutFolder(astroConfig: AstroConfig, pathname: string, routeType: Rou
}
function getOutFile(astroConfig: AstroConfig, outFolder: URL, pathname: string, routeType: RouteType): URL {
switch(routeType) {
switch (routeType) {
case 'endpoint':
return new URL(npath.basename(pathname), outFolder);
case 'page':

View file

@ -91,7 +91,6 @@ export async function render(renderers: Renderer[], mod: ComponentInstance, ssrO
site: astroConfig.buildOptions.site,
});
if (route?.type === 'endpoint') {
return content;
}

View file

@ -48,7 +48,7 @@ describe('Static build', () => {
expect(content.url).to.equal('https://astro.build/');
});
it ('Builds out async .json files', async () => {
it('Builds out async .json files', async () => {
const content = await fixture.readFile('/subpath/posts.json').then((text) => JSON.parse(text));
expect(Array.isArray(content)).to.equal(true);
expect(content).deep.equal([