1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
import type { AstroAdapter, AstroIntegration } from 'astro';
export default function createIntegration(): AstroIntegration {
return {
name: '@benchmark/timer',
hooks: {
'astro:config:setup': ({ updateConfig }) => {
updateConfig({
vite: {
ssr: {
noExternal: ['@benchmark/timer'],
},
},
});
},
'astro:config:done': ({ setAdapter }) => {
setAdapter({
name: '@benchmark/adapter',
serverEntrypoint: '@benchmark/adapter/server.js',
exports: ['manifest', 'createApp'],
supportedAstroFeatures: {
serverOutput: 'stable',
envGetSecret: 'experimental',
staticOutput: 'stable',
hybridOutput: 'stable',
i18nDomains: 'stable',
},
});
},
},
};
}
|