mirror of
https://github.com/withastro/astro.git
synced 2024-12-16 21:46:22 -05:00
[ci] format
This commit is contained in:
parent
8f1d509574
commit
6e0292a1fa
2 changed files with 4 additions and 4 deletions
|
@ -63,9 +63,9 @@ export function createServer(
|
||||||
handler(req, res);
|
handler(req, res);
|
||||||
});
|
});
|
||||||
stream.on('headers', (_res: http.ServerResponse<http.IncomingMessage>) => {
|
stream.on('headers', (_res: http.ServerResponse<http.IncomingMessage>) => {
|
||||||
if(isImmutableAsset(encodedURI)) {
|
if (isImmutableAsset(encodedURI)) {
|
||||||
// Taken from https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control#immutable
|
// Taken from https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cache-Control#immutable
|
||||||
_res.setHeader('Cache-Control', 'public, max-age=31536000, immutable')
|
_res.setHeader('Cache-Control', 'public, max-age=31536000, immutable');
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
stream.on('directory', () => {
|
stream.on('directory', () => {
|
||||||
|
|
|
@ -16,8 +16,8 @@ describe('Assets', () => {
|
||||||
vite: {
|
vite: {
|
||||||
build: {
|
build: {
|
||||||
assetsInlineLimit: 0,
|
assetsInlineLimit: 0,
|
||||||
}
|
},
|
||||||
}
|
},
|
||||||
});
|
});
|
||||||
await fixture.build();
|
await fixture.build();
|
||||||
devPreview = await fixture.preview();
|
devPreview = await fixture.preview();
|
||||||
|
|
Loading…
Reference in a new issue