astro 3.0.0-beta.0 → 3.0.0-beta.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/astro-jsx.d.ts +2 -0
- package/components/ViewTransitions.astro +8 -3
- package/content-types.template.d.ts +6 -6
- package/dist/@types/astro.d.ts +43 -18
- package/dist/@types/astro.js +0 -1
- package/dist/assets/services/vendor/squoosh/impl.js +1 -1
- package/dist/cli/add/babel.d.ts +1 -1
- package/dist/cli/add/index.js +0 -5
- package/dist/cli/check/index.js +7 -1
- package/dist/content/types-generator.js +1 -1
- package/dist/content/vite-plugin-content-imports.js +2 -1
- package/dist/core/app/index.js +32 -58
- package/dist/core/app/ssrPipeline.d.ts +14 -0
- package/dist/core/app/ssrPipeline.js +47 -0
- package/dist/core/app/types.d.ts +0 -2
- package/dist/core/build/generate.js +4 -5
- package/dist/core/build/plugins/index.js +1 -1
- package/dist/core/build/plugins/plugin-analyzer.d.ts +3 -2
- package/dist/core/build/plugins/plugin-analyzer.js +24 -25
- package/dist/core/build/plugins/plugin-renderers.js +2 -0
- package/dist/core/build/plugins/plugin-ssr.js +0 -1
- package/dist/core/build/static-build.js +3 -14
- package/dist/core/compile/compile.js +1 -0
- package/dist/core/compile/style.js +1 -0
- package/dist/core/config/config.d.ts +6 -0
- package/dist/core/config/config.js +3 -0
- package/dist/core/config/schema.d.ts +24 -8
- package/dist/core/config/schema.js +11 -15
- package/dist/core/config/settings.js +2 -2
- package/dist/core/constants.js +1 -1
- package/dist/core/cookies/index.d.ts +1 -1
- package/dist/core/cookies/index.js +2 -2
- package/dist/core/cookies/response.d.ts +1 -1
- package/dist/core/cookies/response.js +2 -2
- package/dist/core/create-vite.js +3 -3
- package/dist/core/dev/dev.js +1 -1
- package/dist/core/endpoint/index.d.ts +2 -5
- package/dist/core/endpoint/index.js +3 -4
- package/dist/core/errors/dev/vite.js +10 -10
- package/dist/core/errors/errors-data.d.ts +1048 -983
- package/dist/core/errors/errors-data.js +446 -1017
- package/dist/core/errors/errors.d.ts +16 -2
- package/dist/core/errors/errors.js +18 -10
- package/dist/core/errors/index.d.ts +2 -2
- package/dist/core/errors/index.js +4 -2
- package/dist/core/errors/userError.d.ts +1 -0
- package/dist/core/errors/userError.js +4 -0
- package/dist/core/errors/utils.d.ts +0 -5
- package/dist/core/errors/utils.js +0 -11
- package/dist/core/messages.js +8 -4
- package/dist/core/pipeline.d.ts +44 -0
- package/dist/core/pipeline.js +124 -0
- package/dist/core/render/context.d.ts +2 -1
- package/dist/core/render/core.d.ts +3 -1
- package/dist/core/render/core.js +6 -6
- package/dist/core/render/environment.d.ts +0 -5
- package/dist/core/render/index.d.ts +1 -1
- package/dist/core/render/result.d.ts +0 -5
- package/dist/core/render/result.js +1 -20
- package/dist/core/util.js +3 -2
- package/dist/jsx/babel.js +1 -1
- package/dist/jsx/renderer.js +2 -4
- package/dist/jsx/server.js +2 -8
- package/dist/runtime/server/astro-island.js +15 -11
- package/dist/runtime/server/astro-island.prebuilt.d.ts +1 -1
- package/dist/runtime/server/astro-island.prebuilt.js +1 -1
- package/dist/runtime/server/index.d.ts +1 -1
- package/dist/runtime/server/index.js +2 -1
- package/dist/runtime/server/render/page.js +1 -2
- package/dist/runtime/server/render/util.js +0 -2
- package/dist/runtime/server/serialize.js +7 -12
- package/dist/template/4xx.js +27 -5
- package/dist/transitions/vite-plugin-transitions.js +1 -0
- package/dist/vite-plugin-astro-server/environment.js +0 -1
- package/dist/vite-plugin-astro-server/plugin.js +0 -1
- package/dist/vite-plugin-astro-server/request.js +2 -2
- package/dist/vite-plugin-astro-server/route.d.ts +1 -1
- package/dist/vite-plugin-astro-server/route.js +17 -14
- package/dist/vite-plugin-inject-env-ts/index.js +0 -2
- package/dist/vite-plugin-integrations-container/index.js +17 -0
- package/dist/vite-plugin-markdown/index.js +20 -19
- package/dist/{vite-plugin-jsx → vite-plugin-mdx}/index.d.ts +1 -1
- package/dist/vite-plugin-mdx/index.js +102 -0
- package/package.json +5 -5
- package/dist/runtime/server/response.d.ts +0 -3
- package/dist/runtime/server/response.js +0 -69
- package/dist/vite-plugin-jsx/index.js +0 -207
- /package/dist/{vite-plugin-jsx → vite-plugin-mdx}/import-source.d.ts +0 -0
- /package/dist/{vite-plugin-jsx → vite-plugin-mdx}/import-source.js +0 -0
- /package/dist/{vite-plugin-jsx → vite-plugin-mdx}/tag.d.ts +0 -0
- /package/dist/{vite-plugin-jsx → vite-plugin-mdx}/tag.js +0 -0
package/astro-jsx.d.ts
CHANGED
|
@@ -9,6 +9,8 @@
|
|
|
9
9
|
* Adapted from React’s TypeScript definition from DefinitelyTyped.
|
|
10
10
|
* @see https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/react/index.d.ts
|
|
11
11
|
*/
|
|
12
|
+
// BUG! Prettier 3.0 removes `declare`: https://github.com/prettier/prettier/issues/15207
|
|
13
|
+
// prettier-ignore
|
|
12
14
|
declare namespace astroHTML.JSX {
|
|
13
15
|
export type Child = Node | Node[] | string | number | boolean | null | undefined | unknown;
|
|
14
16
|
export type Children = Child | Child[];
|
|
@@ -168,13 +168,18 @@ const { fallback = 'animate' } = Astro.props as Props;
|
|
|
168
168
|
|
|
169
169
|
// Trigger the animations
|
|
170
170
|
document.documentElement.dataset.astroTransitionFallback = 'old';
|
|
171
|
-
|
|
171
|
+
const fallbackSwap = () => {
|
|
172
|
+
removeEventListener('animationend', fallbackSwap);
|
|
173
|
+
clearTimeout(timeout);
|
|
174
|
+
swap();
|
|
175
|
+
document.documentElement.dataset.astroTransitionFallback = 'new';
|
|
176
|
+
};
|
|
172
177
|
// If there are any animations, want for the animationend event.
|
|
173
|
-
addEventListener('animationend',
|
|
178
|
+
addEventListener('animationend', fallbackSwap, { once: true });
|
|
174
179
|
// If there are no animations, go ahead and swap on next tick
|
|
175
180
|
// This is necessary because we do not know if there are animations.
|
|
176
181
|
// The setTimeout is a fallback in case there are none.
|
|
177
|
-
setTimeout(() => !isAnimating &&
|
|
182
|
+
let timeout = setTimeout(() => !isAnimating && fallbackSwap());
|
|
178
183
|
} else {
|
|
179
184
|
swap();
|
|
180
185
|
}
|
|
@@ -44,7 +44,7 @@ declare module 'astro:content' {
|
|
|
44
44
|
import('astro/zod').ZodLiteral<'tiff'>,
|
|
45
45
|
import('astro/zod').ZodLiteral<'webp'>,
|
|
46
46
|
import('astro/zod').ZodLiteral<'gif'>,
|
|
47
|
-
import('astro/zod').ZodLiteral<'svg'
|
|
47
|
+
import('astro/zod').ZodLiteral<'svg'>,
|
|
48
48
|
]
|
|
49
49
|
>;
|
|
50
50
|
}>;
|
|
@@ -87,7 +87,7 @@ declare module 'astro:content' {
|
|
|
87
87
|
|
|
88
88
|
export function getEntryBySlug<
|
|
89
89
|
C extends keyof ContentEntryMap,
|
|
90
|
-
E extends ValidContentEntrySlug<C> | (string & {})
|
|
90
|
+
E extends ValidContentEntrySlug<C> | (string & {}),
|
|
91
91
|
>(
|
|
92
92
|
collection: C,
|
|
93
93
|
// Note that this has to accept a regular string too, for SSR
|
|
@@ -112,7 +112,7 @@ declare module 'astro:content' {
|
|
|
112
112
|
|
|
113
113
|
export function getEntry<
|
|
114
114
|
C extends keyof ContentEntryMap,
|
|
115
|
-
E extends ValidContentEntrySlug<C> | (string & {})
|
|
115
|
+
E extends ValidContentEntrySlug<C> | (string & {}),
|
|
116
116
|
>(entry: {
|
|
117
117
|
collection: C;
|
|
118
118
|
slug: E;
|
|
@@ -121,7 +121,7 @@ declare module 'astro:content' {
|
|
|
121
121
|
: Promise<CollectionEntry<C> | undefined>;
|
|
122
122
|
export function getEntry<
|
|
123
123
|
C extends keyof DataEntryMap,
|
|
124
|
-
E extends keyof DataEntryMap[C] | (string & {})
|
|
124
|
+
E extends keyof DataEntryMap[C] | (string & {}),
|
|
125
125
|
>(entry: {
|
|
126
126
|
collection: C;
|
|
127
127
|
id: E;
|
|
@@ -130,7 +130,7 @@ declare module 'astro:content' {
|
|
|
130
130
|
: Promise<CollectionEntry<C> | undefined>;
|
|
131
131
|
export function getEntry<
|
|
132
132
|
C extends keyof ContentEntryMap,
|
|
133
|
-
E extends ValidContentEntrySlug<C> | (string & {})
|
|
133
|
+
E extends ValidContentEntrySlug<C> | (string & {}),
|
|
134
134
|
>(
|
|
135
135
|
collection: C,
|
|
136
136
|
slug: E
|
|
@@ -139,7 +139,7 @@ declare module 'astro:content' {
|
|
|
139
139
|
: Promise<CollectionEntry<C> | undefined>;
|
|
140
140
|
export function getEntry<
|
|
141
141
|
C extends keyof DataEntryMap,
|
|
142
|
-
E extends keyof DataEntryMap[C] | (string & {})
|
|
142
|
+
E extends keyof DataEntryMap[C] | (string & {}),
|
|
143
143
|
>(
|
|
144
144
|
collection: C,
|
|
145
145
|
id: E
|
package/dist/@types/astro.d.ts
CHANGED
|
@@ -15,7 +15,7 @@ import type { AstroConfigSchema } from '../core/config';
|
|
|
15
15
|
import type { AstroTimer } from '../core/config/timer';
|
|
16
16
|
import type { AstroCookies } from '../core/cookies';
|
|
17
17
|
import type { LogOptions, LoggerLevel } from '../core/logger/core';
|
|
18
|
-
import { AstroIntegrationLogger } from '../core/logger/core';
|
|
18
|
+
import type { AstroIntegrationLogger } from '../core/logger/core';
|
|
19
19
|
import type { AstroComponentFactory, AstroComponentInstance } from '../runtime/server';
|
|
20
20
|
import type { SUPPORTED_MARKDOWN_FILE_EXTENSIONS } from './../core/constants.js';
|
|
21
21
|
export type { MarkdownHeading, MarkdownMetadata, MarkdownRenderingResult, RehypePlugins, RemarkPlugins, ShikiConfig, } from '@astrojs/markdown-remark';
|
|
@@ -508,12 +508,7 @@ export interface AstroUserConfig {
|
|
|
508
508
|
*
|
|
509
509
|
* When using this option, all of your static asset imports and URLs should add the base as a prefix. You can access this value via `import.meta.env.BASE_URL`.
|
|
510
510
|
*
|
|
511
|
-
*
|
|
512
|
-
*
|
|
513
|
-
* ```astro
|
|
514
|
-
* <a href="/docs/about/">About</a>
|
|
515
|
-
* <img src=`${import.meta.env.BASE_URL}image.png`>
|
|
516
|
-
* ```
|
|
511
|
+
* The value of `import.meta.env.BASE_URL` respects your `trailingSlash` config and will include a trailing slash if you explicitly include one or if `trailingSlash: "always"` is set. If `trailingSlash: "never"` is set, `BASE_URL` will not include a trailing slash, even if `base` includes one.
|
|
517
512
|
*/
|
|
518
513
|
base?: string;
|
|
519
514
|
/**
|
|
@@ -544,19 +539,21 @@ export interface AstroUserConfig {
|
|
|
544
539
|
/**
|
|
545
540
|
* @docs
|
|
546
541
|
* @name scopedStyleStrategy
|
|
547
|
-
* @type {('where' | 'class')}
|
|
542
|
+
* @type {('where' | 'class' | 'attribute')}
|
|
548
543
|
* @default `'where'`
|
|
549
544
|
* @version 2.4
|
|
550
545
|
* @description
|
|
551
546
|
*
|
|
552
547
|
* Specify the strategy used for scoping styles within Astro components. Choose from:
|
|
553
|
-
* - `'where'`
|
|
554
|
-
* - `'class'`
|
|
548
|
+
* - `'where'` - Use `:where` selectors, causing no specifity increase.
|
|
549
|
+
* - `'class'` - Use class-based selectors, causing a +1 specifity increase.
|
|
550
|
+
* - `'attribute'` - Use `data-` attributes, causing no specifity increase.
|
|
555
551
|
*
|
|
556
552
|
* Using `'class'` is helpful when you want to ensure that element selectors within an Astro component override global style defaults (e.g. from a global stylesheet).
|
|
557
553
|
* Using `'where'` gives you more control over specifity, but requires that you use higher-specifity selectors, layers, and other tools to control which selectors are applied.
|
|
554
|
+
* Using `'attribute'` is useful in case there's manipulation of the class attributes, so the styling emitted by Astro doesn't go in conflict with the user's business logic.
|
|
558
555
|
*/
|
|
559
|
-
scopedStyleStrategy?: 'where' | 'class';
|
|
556
|
+
scopedStyleStrategy?: 'where' | 'class' | 'attribute';
|
|
560
557
|
/**
|
|
561
558
|
* @docs
|
|
562
559
|
* @name adapter
|
|
@@ -1187,6 +1184,27 @@ export interface AstroUserConfig {
|
|
|
1187
1184
|
* ```
|
|
1188
1185
|
*/
|
|
1189
1186
|
viewTransitions?: boolean;
|
|
1187
|
+
/**
|
|
1188
|
+
* @docs
|
|
1189
|
+
* @name experimental.optimizeHoistedScript
|
|
1190
|
+
* @type {boolean}
|
|
1191
|
+
* @default `false`
|
|
1192
|
+
* @version 2.10.4
|
|
1193
|
+
* @description
|
|
1194
|
+
* Prevents unused components' scripts from being included in a page unexpectedly.
|
|
1195
|
+
* The optimization is best-effort and may inversely miss including the used scripts. Make sure to double-check your built pages
|
|
1196
|
+
* before publishing.
|
|
1197
|
+
* Enable hoisted script analysis optimization by adding the experimental flag:
|
|
1198
|
+
*
|
|
1199
|
+
* ```js
|
|
1200
|
+
* {
|
|
1201
|
+
* experimental: {
|
|
1202
|
+
* optimizeHoistedScript: true,
|
|
1203
|
+
* },
|
|
1204
|
+
* }
|
|
1205
|
+
* ```
|
|
1206
|
+
*/
|
|
1207
|
+
optimizeHoistedScript?: boolean;
|
|
1190
1208
|
};
|
|
1191
1209
|
/** @deprecated - Use "integrations" instead. Run Astro to learn more about migrating. */
|
|
1192
1210
|
renderers?: never;
|
|
@@ -1217,15 +1235,18 @@ export interface AstroUserConfig {
|
|
|
1217
1235
|
* - "page-ssr": Injected into the frontmatter of every Astro page. Processed & resolved by Vite.
|
|
1218
1236
|
*/
|
|
1219
1237
|
export type InjectedScriptStage = 'before-hydration' | 'head-inline' | 'page' | 'page-ssr';
|
|
1220
|
-
/**
|
|
1221
|
-
* Resolved Astro Config
|
|
1222
|
-
* Config with user settings along with all defaults filled in.
|
|
1223
|
-
*/
|
|
1224
1238
|
export interface InjectedRoute {
|
|
1225
1239
|
pattern: string;
|
|
1226
1240
|
entryPoint: string;
|
|
1227
1241
|
prerender?: boolean;
|
|
1228
1242
|
}
|
|
1243
|
+
export interface ResolvedInjectedRoute extends InjectedRoute {
|
|
1244
|
+
resolvedEntryPoint?: URL;
|
|
1245
|
+
}
|
|
1246
|
+
/**
|
|
1247
|
+
* Resolved Astro Config
|
|
1248
|
+
* Config with user settings along with all defaults filled in.
|
|
1249
|
+
*/
|
|
1229
1250
|
export interface AstroConfig extends z.output<typeof AstroConfigSchema> {
|
|
1230
1251
|
integrations: AstroIntegration[];
|
|
1231
1252
|
}
|
|
@@ -1315,6 +1336,7 @@ export interface AstroSettings {
|
|
|
1315
1336
|
config: AstroConfig;
|
|
1316
1337
|
adapter: AstroAdapter | undefined;
|
|
1317
1338
|
injectedRoutes: InjectedRoute[];
|
|
1339
|
+
resolvedInjectedRoutes: ResolvedInjectedRoute[];
|
|
1318
1340
|
pageExtensions: string[];
|
|
1319
1341
|
contentEntryTypes: ContentEntryType[];
|
|
1320
1342
|
dataEntryTypes: DataEntryType[];
|
|
@@ -1697,10 +1719,13 @@ export interface APIContext<Props extends Record<string, any> = Record<string, a
|
|
|
1697
1719
|
*/
|
|
1698
1720
|
locals: App.Locals;
|
|
1699
1721
|
}
|
|
1700
|
-
export
|
|
1722
|
+
export type EndpointOutput = {
|
|
1701
1723
|
body: Body;
|
|
1702
|
-
encoding?: BufferEncoding
|
|
1703
|
-
}
|
|
1724
|
+
encoding?: Exclude<BufferEncoding, 'binary'>;
|
|
1725
|
+
} | {
|
|
1726
|
+
body: Uint8Array;
|
|
1727
|
+
encoding: 'binary';
|
|
1728
|
+
};
|
|
1704
1729
|
export type APIRoute<Props extends Record<string, any> = Record<string, any>> = (context: APIContext<Props>) => EndpointOutput | Response | Promise<EndpointOutput | Response>;
|
|
1705
1730
|
export interface EndpointHandler {
|
|
1706
1731
|
[method: string]: APIRoute | ((params: Params, request: Request) => EndpointOutput | Response);
|
package/dist/@types/astro.js
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import { AstroIntegrationLogger } from "../core/logger/core";
|
|
@@ -22,7 +22,7 @@ async function decodeBuffer(_buffer) {
|
|
|
22
22
|
const firstChunk = buffer.slice(0, 16);
|
|
23
23
|
const firstChunkString = Array.from(firstChunk).map((v) => String.fromCodePoint(v)).join("");
|
|
24
24
|
if (firstChunkString.includes("GIF")) {
|
|
25
|
-
throw Error(`GIF images are not supported, please
|
|
25
|
+
throw Error(`GIF images are not supported, please use the Sharp image service`);
|
|
26
26
|
}
|
|
27
27
|
const key = Object.entries(supportedFormats).find(
|
|
28
28
|
([, { detectors }]) => detectors.some((detector) => detector.exec(firstChunkString))
|
package/dist/cli/add/babel.d.ts
CHANGED
|
@@ -10,7 +10,7 @@ export declare const visit: {
|
|
|
10
10
|
node: (node: t.Node, opts: import("@babel/traverse").TraverseOptions<t.Node>, scope?: import("@babel/traverse").Scope | undefined, state?: any, path?: import("@babel/traverse").NodePath<t.Node> | undefined, skipKeys?: Record<string, boolean> | undefined) => void;
|
|
11
11
|
clearNode: (node: t.Node, opts?: t.RemovePropertiesOptions | undefined) => void;
|
|
12
12
|
removeProperties: (tree: t.Node, opts?: t.RemovePropertiesOptions | undefined) => t.Node;
|
|
13
|
-
hasType: (tree: t.Node, type: "
|
|
13
|
+
hasType: (tree: t.Node, type: "File" | "AnyTypeAnnotation" | "ArgumentPlaceholder" | "ArrayExpression" | "ArrayPattern" | "ArrayTypeAnnotation" | "ArrowFunctionExpression" | "AssignmentExpression" | "AssignmentPattern" | "AwaitExpression" | "BigIntLiteral" | "BinaryExpression" | "BindExpression" | "BlockStatement" | "BooleanLiteral" | "BooleanLiteralTypeAnnotation" | "BooleanTypeAnnotation" | "BreakStatement" | "CallExpression" | "CatchClause" | "ClassAccessorProperty" | "ClassBody" | "ClassDeclaration" | "ClassExpression" | "ClassImplements" | "ClassMethod" | "ClassPrivateMethod" | "ClassPrivateProperty" | "ClassProperty" | "ConditionalExpression" | "ContinueStatement" | "DebuggerStatement" | "DecimalLiteral" | "DeclareClass" | "DeclareExportAllDeclaration" | "DeclareExportDeclaration" | "DeclareFunction" | "DeclareInterface" | "DeclareModule" | "DeclareModuleExports" | "DeclareOpaqueType" | "DeclareTypeAlias" | "DeclareVariable" | "DeclaredPredicate" | "Decorator" | "Directive" | "DirectiveLiteral" | "DoExpression" | "DoWhileStatement" | "EmptyStatement" | "EmptyTypeAnnotation" | "EnumBooleanBody" | "EnumBooleanMember" | "EnumDeclaration" | "EnumDefaultedMember" | "EnumNumberBody" | "EnumNumberMember" | "EnumStringBody" | "EnumStringMember" | "EnumSymbolBody" | "ExistsTypeAnnotation" | "ExportAllDeclaration" | "ExportDefaultDeclaration" | "ExportDefaultSpecifier" | "ExportNamedDeclaration" | "ExportNamespaceSpecifier" | "ExportSpecifier" | "ExpressionStatement" | "ForInStatement" | "ForOfStatement" | "ForStatement" | "FunctionDeclaration" | "FunctionExpression" | "FunctionTypeAnnotation" | "FunctionTypeParam" | "GenericTypeAnnotation" | "Identifier" | "IfStatement" | "Import" | "ImportAttribute" | "ImportDeclaration" | "ImportDefaultSpecifier" | "ImportNamespaceSpecifier" | "ImportSpecifier" | "IndexedAccessType" | "InferredPredicate" | "InterfaceDeclaration" | "InterfaceExtends" | "InterfaceTypeAnnotation" | "InterpreterDirective" | "IntersectionTypeAnnotation" | "JSXAttribute" | "JSXClosingElement" | "JSXClosingFragment" | "JSXElement" | "JSXEmptyExpression" | "JSXExpressionContainer" | "JSXFragment" | "JSXIdentifier" | "JSXMemberExpression" | "JSXNamespacedName" | "JSXOpeningElement" | "JSXOpeningFragment" | "JSXSpreadAttribute" | "JSXSpreadChild" | "JSXText" | "LabeledStatement" | "LogicalExpression" | "MemberExpression" | "MetaProperty" | "MixedTypeAnnotation" | "ModuleExpression" | "NewExpression" | "Noop" | "NullLiteral" | "NullLiteralTypeAnnotation" | "NullableTypeAnnotation" | "NumberLiteral" | "NumberLiteralTypeAnnotation" | "NumberTypeAnnotation" | "NumericLiteral" | "ObjectExpression" | "ObjectMethod" | "ObjectPattern" | "ObjectProperty" | "ObjectTypeAnnotation" | "ObjectTypeCallProperty" | "ObjectTypeIndexer" | "ObjectTypeInternalSlot" | "ObjectTypeProperty" | "ObjectTypeSpreadProperty" | "OpaqueType" | "OptionalCallExpression" | "OptionalIndexedAccessType" | "OptionalMemberExpression" | "ParenthesizedExpression" | "PipelineBareFunction" | "PipelinePrimaryTopicReference" | "PipelineTopicExpression" | "Placeholder" | "PrivateName" | "Program" | "QualifiedTypeIdentifier" | "RecordExpression" | "RegExpLiteral" | "RegexLiteral" | "RestElement" | "RestProperty" | "ReturnStatement" | "SequenceExpression" | "SpreadElement" | "SpreadProperty" | "StaticBlock" | "StringLiteral" | "StringLiteralTypeAnnotation" | "StringTypeAnnotation" | "Super" | "SwitchCase" | "SwitchStatement" | "SymbolTypeAnnotation" | "TSAnyKeyword" | "TSArrayType" | "TSAsExpression" | "TSBigIntKeyword" | "TSBooleanKeyword" | "TSCallSignatureDeclaration" | "TSConditionalType" | "TSConstructSignatureDeclaration" | "TSConstructorType" | "TSDeclareFunction" | "TSDeclareMethod" | "TSEnumDeclaration" | "TSEnumMember" | "TSExportAssignment" | "TSExpressionWithTypeArguments" | "TSExternalModuleReference" | "TSFunctionType" | "TSImportEqualsDeclaration" | "TSImportType" | "TSIndexSignature" | "TSIndexedAccessType" | "TSInferType" | "TSInstantiationExpression" | "TSInterfaceBody" | "TSInterfaceDeclaration" | "TSIntersectionType" | "TSIntrinsicKeyword" | "TSLiteralType" | "TSMappedType" | "TSMethodSignature" | "TSModuleBlock" | "TSModuleDeclaration" | "TSNamedTupleMember" | "TSNamespaceExportDeclaration" | "TSNeverKeyword" | "TSNonNullExpression" | "TSNullKeyword" | "TSNumberKeyword" | "TSObjectKeyword" | "TSOptionalType" | "TSParameterProperty" | "TSParenthesizedType" | "TSPropertySignature" | "TSQualifiedName" | "TSRestType" | "TSSatisfiesExpression" | "TSStringKeyword" | "TSSymbolKeyword" | "TSThisType" | "TSTupleType" | "TSTypeAliasDeclaration" | "TSTypeAnnotation" | "TSTypeAssertion" | "TSTypeLiteral" | "TSTypeOperator" | "TSTypeParameter" | "TSTypeParameterDeclaration" | "TSTypeParameterInstantiation" | "TSTypePredicate" | "TSTypeQuery" | "TSTypeReference" | "TSUndefinedKeyword" | "TSUnionType" | "TSUnknownKeyword" | "TSVoidKeyword" | "TaggedTemplateExpression" | "TemplateElement" | "TemplateLiteral" | "ThisExpression" | "ThisTypeAnnotation" | "ThrowStatement" | "TopicReference" | "TryStatement" | "TupleExpression" | "TupleTypeAnnotation" | "TypeAlias" | "TypeAnnotation" | "TypeCastExpression" | "TypeParameter" | "TypeParameterDeclaration" | "TypeParameterInstantiation" | "TypeofTypeAnnotation" | "UnaryExpression" | "UnionTypeAnnotation" | "UpdateExpression" | "V8IntrinsicIdentifier" | "VariableDeclaration" | "VariableDeclarator" | "Variance" | "VoidTypeAnnotation" | "WhileStatement" | "WithStatement" | "YieldExpression", denylistTypes?: string[] | undefined) => boolean;
|
|
14
14
|
cache: typeof import("@babel/traverse").cache;
|
|
15
15
|
};
|
|
16
16
|
export { t };
|
package/dist/cli/add/index.js
CHANGED
|
@@ -184,11 +184,6 @@ async function add(names, { flags }) {
|
|
|
184
184
|
configURL = new URL("./astro.config.mjs", root);
|
|
185
185
|
await fs.writeFile(fileURLToPath(configURL), ASTRO_CONFIG_STUB, { encoding: "utf-8" });
|
|
186
186
|
}
|
|
187
|
-
if (configURL?.pathname.endsWith("package.json")) {
|
|
188
|
-
throw new Error(
|
|
189
|
-
`Unable to use "astro add" with package.json configuration. Try migrating to \`astro.config.mjs\` and try again.`
|
|
190
|
-
);
|
|
191
|
-
}
|
|
192
187
|
let ast = null;
|
|
193
188
|
try {
|
|
194
189
|
ast = await parseAstroConfig(configURL);
|
package/dist/cli/check/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import path from "node:path";
|
|
2
2
|
import { error, info } from "../../core/logger/core.js";
|
|
3
|
-
import { createLoggingFromFlags } from "../flags.js";
|
|
3
|
+
import { createLoggingFromFlags, flagsToAstroInlineConfig } from "../flags.js";
|
|
4
4
|
import { getPackage } from "../install-package.js";
|
|
5
5
|
async function check(flags) {
|
|
6
6
|
const logging = createLoggingFromFlags(flags);
|
|
@@ -20,6 +20,12 @@ async function check(flags) {
|
|
|
20
20
|
);
|
|
21
21
|
return;
|
|
22
22
|
}
|
|
23
|
+
const { sync } = await import("../../core/sync/index.js");
|
|
24
|
+
const inlineConfig = flagsToAstroInlineConfig(flags);
|
|
25
|
+
const exitCode = await sync(inlineConfig);
|
|
26
|
+
if (exitCode !== 0) {
|
|
27
|
+
process.exit(exitCode);
|
|
28
|
+
}
|
|
23
29
|
const { check: checker, parseArgsAsCheckConfig } = checkPackage;
|
|
24
30
|
const config = parseArgsAsCheckConfig(process.argv);
|
|
25
31
|
info(logging, "check", `Getting diagnostics for Astro files in ${path.resolve(config.root)}...`);
|
|
@@ -3,8 +3,8 @@ import { cyan } from "kleur/colors";
|
|
|
3
3
|
import * as path from "node:path";
|
|
4
4
|
import { fileURLToPath, pathToFileURL } from "node:url";
|
|
5
5
|
import { normalizePath } from "vite";
|
|
6
|
-
import { AstroErrorData } from "../core/errors/errors-data.js";
|
|
7
6
|
import { AstroError } from "../core/errors/errors.js";
|
|
7
|
+
import { AstroErrorData } from "../core/errors/index.js";
|
|
8
8
|
import { info, warn } from "../core/logger/core.js";
|
|
9
9
|
import { isRelativePath } from "../core/path.js";
|
|
10
10
|
import { CONTENT_TYPES_FILE, VIRTUAL_MODULE_ID } from "./consts.js";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as devalue from "devalue";
|
|
2
2
|
import { extname } from "node:path";
|
|
3
3
|
import { pathToFileURL } from "node:url";
|
|
4
|
-
import { AstroErrorData } from "../core/errors/errors-data.js";
|
|
5
4
|
import { AstroError } from "../core/errors/errors.js";
|
|
5
|
+
import { AstroErrorData } from "../core/errors/index.js";
|
|
6
6
|
import { escapeViteEnvReferences } from "../vite-plugin-utils/index.js";
|
|
7
7
|
import { CONTENT_FLAG, DATA_FLAG } from "./consts.js";
|
|
8
8
|
import {
|
|
@@ -277,6 +277,7 @@ function stringifyEntryData(data) {
|
|
|
277
277
|
});
|
|
278
278
|
} else {
|
|
279
279
|
throw new AstroError({
|
|
280
|
+
name: "PluginContentImportsError",
|
|
280
281
|
message: "Unexpected error processing content collection data."
|
|
281
282
|
});
|
|
282
283
|
}
|
package/dist/core/app/index.js
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { attachToResponse, getSetCookiesFromResponse } from "../cookies/index.js";
|
|
1
|
+
import { getSetCookiesFromResponse } from "../cookies/index.js";
|
|
3
2
|
import { consoleLogDestination } from "../logger/console.js";
|
|
4
3
|
import { error } from "../logger/core.js";
|
|
5
|
-
import {
|
|
4
|
+
import {
|
|
5
|
+
collapseDuplicateSlashes,
|
|
6
|
+
prependForwardSlash,
|
|
7
|
+
removeTrailingForwardSlash
|
|
8
|
+
} from "../path.js";
|
|
6
9
|
import { RedirectSinglePageBuiltModule } from "../redirects/index.js";
|
|
7
|
-
import { isResponse } from "../render/core.js";
|
|
8
10
|
import {
|
|
9
11
|
createEnvironment,
|
|
10
12
|
createRenderContext,
|
|
@@ -17,6 +19,7 @@ import {
|
|
|
17
19
|
createStylesheetElementSet
|
|
18
20
|
} from "../render/ssr-element.js";
|
|
19
21
|
import { matchRoute } from "../routing/match.js";
|
|
22
|
+
import { EndpointNotFoundError, SSRRoutePipeline } from "./ssrPipeline.js";
|
|
20
23
|
import { deserializeManifest } from "./common.js";
|
|
21
24
|
const clientLocalsSymbol = Symbol.for("astro.locals");
|
|
22
25
|
const responseSentSymbol = Symbol.for("astro.responseSent");
|
|
@@ -25,16 +28,15 @@ class App {
|
|
|
25
28
|
/**
|
|
26
29
|
* The current environment of the application
|
|
27
30
|
*/
|
|
28
|
-
#env;
|
|
29
31
|
#manifest;
|
|
30
32
|
#manifestData;
|
|
31
33
|
#routeDataToRouteInfo;
|
|
32
|
-
#encoder = new TextEncoder();
|
|
33
34
|
#logging = {
|
|
34
35
|
dest: consoleLogDestination,
|
|
35
36
|
level: "info"
|
|
36
37
|
};
|
|
37
38
|
#baseWithoutTrailingSlash;
|
|
39
|
+
#pipeline;
|
|
38
40
|
constructor(manifest, streaming = true) {
|
|
39
41
|
this.#manifest = manifest;
|
|
40
42
|
this.#manifestData = {
|
|
@@ -42,7 +44,7 @@ class App {
|
|
|
42
44
|
};
|
|
43
45
|
this.#routeDataToRouteInfo = new Map(manifest.routes.map((route) => [route.routeData, route]));
|
|
44
46
|
this.#baseWithoutTrailingSlash = removeTrailingForwardSlash(this.#manifest.base);
|
|
45
|
-
this.#
|
|
47
|
+
this.#pipeline = new SSRRoutePipeline(this.#createEnvironment(streaming));
|
|
46
48
|
}
|
|
47
49
|
set setManifest(newManifest) {
|
|
48
50
|
this.#manifest = newManifest;
|
|
@@ -57,7 +59,6 @@ class App {
|
|
|
57
59
|
return createEnvironment({
|
|
58
60
|
adapterName: this.#manifest.adapterName,
|
|
59
61
|
logging: this.#logging,
|
|
60
|
-
markdown: this.#manifest.markdown,
|
|
61
62
|
mode: "production",
|
|
62
63
|
compressHTML: this.#manifest.compressHTML,
|
|
63
64
|
renderers: this.#manifest.renderers,
|
|
@@ -98,18 +99,21 @@ class App {
|
|
|
98
99
|
const url = new URL(request.url);
|
|
99
100
|
if (this.#manifest.assets.has(url.pathname))
|
|
100
101
|
return void 0;
|
|
101
|
-
|
|
102
|
-
|
|
102
|
+
const pathname = prependForwardSlash(this.removeBase(url.pathname));
|
|
103
|
+
const routeData = matchRoute(pathname, this.#manifestData);
|
|
103
104
|
if (!routeData || routeData.prerender)
|
|
104
105
|
return void 0;
|
|
105
106
|
return routeData;
|
|
106
107
|
}
|
|
107
108
|
async render(request, routeData, locals) {
|
|
109
|
+
if (request.url !== collapseDuplicateSlashes(request.url)) {
|
|
110
|
+
request = new Request(collapseDuplicateSlashes(request.url), request);
|
|
111
|
+
}
|
|
108
112
|
if (!routeData) {
|
|
109
113
|
routeData = this.match(request);
|
|
110
114
|
}
|
|
111
115
|
if (!routeData) {
|
|
112
|
-
return this.#renderError(request, {
|
|
116
|
+
return this.#renderError(request, { status: 404 });
|
|
113
117
|
}
|
|
114
118
|
Reflect.set(request, clientLocalsSymbol, locals ?? {});
|
|
115
119
|
const defaultStatus = this.#getDefaultStatusCode(routeData.route);
|
|
@@ -125,56 +129,29 @@ class App {
|
|
|
125
129
|
);
|
|
126
130
|
let response;
|
|
127
131
|
try {
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
pageModule,
|
|
133
|
-
mod.onRequest
|
|
134
|
-
);
|
|
132
|
+
if (mod.onRequest) {
|
|
133
|
+
this.#pipeline.setMiddlewareFunction(mod.onRequest);
|
|
134
|
+
}
|
|
135
|
+
response = await this.#pipeline.renderRoute(renderContext, pageModule);
|
|
135
136
|
} catch (err) {
|
|
136
|
-
|
|
137
|
-
|
|
137
|
+
if (err instanceof EndpointNotFoundError) {
|
|
138
|
+
return this.#renderError(request, { status: 404, response: err.originalResponse });
|
|
139
|
+
} else {
|
|
140
|
+
error(this.#logging, "ssr", err.stack || err.message || String(err));
|
|
141
|
+
return this.#renderError(request, { status: 500 });
|
|
142
|
+
}
|
|
138
143
|
}
|
|
139
|
-
if (isResponse(response, routeData.type)) {
|
|
144
|
+
if (SSRRoutePipeline.isResponse(response, routeData.type)) {
|
|
140
145
|
if (STATUS_CODES.has(response.status)) {
|
|
141
146
|
return this.#renderError(request, {
|
|
142
|
-
routeData,
|
|
143
147
|
response,
|
|
144
148
|
status: response.status
|
|
145
149
|
});
|
|
146
150
|
}
|
|
147
151
|
Reflect.set(response, responseSentSymbol, true);
|
|
148
152
|
return response;
|
|
149
|
-
} else {
|
|
150
|
-
if (response.type === "response") {
|
|
151
|
-
if (response.response.headers.get("X-Astro-Response") === "Not-Found") {
|
|
152
|
-
return this.#renderError(request, {
|
|
153
|
-
routeData,
|
|
154
|
-
response: response.response,
|
|
155
|
-
status: 404
|
|
156
|
-
});
|
|
157
|
-
}
|
|
158
|
-
return response.response;
|
|
159
|
-
} else {
|
|
160
|
-
const body = response.body;
|
|
161
|
-
const headers = new Headers();
|
|
162
|
-
const mimeType = mime.getType(url.pathname);
|
|
163
|
-
if (mimeType) {
|
|
164
|
-
headers.set("Content-Type", `${mimeType};charset=utf-8`);
|
|
165
|
-
} else {
|
|
166
|
-
headers.set("Content-Type", "text/plain;charset=utf-8");
|
|
167
|
-
}
|
|
168
|
-
const bytes = this.#encoder.encode(body);
|
|
169
|
-
headers.set("Content-Length", bytes.byteLength.toString());
|
|
170
|
-
const newResponse = new Response(bytes, {
|
|
171
|
-
status: 200,
|
|
172
|
-
headers
|
|
173
|
-
});
|
|
174
|
-
attachToResponse(newResponse, response.cookies);
|
|
175
|
-
return newResponse;
|
|
176
|
-
}
|
|
177
153
|
}
|
|
154
|
+
return response;
|
|
178
155
|
}
|
|
179
156
|
setCookieHeaders(response) {
|
|
180
157
|
return getSetCookiesFromResponse(response);
|
|
@@ -192,7 +169,7 @@ class App {
|
|
|
192
169
|
pathname,
|
|
193
170
|
route: routeData,
|
|
194
171
|
status,
|
|
195
|
-
env: this.#env,
|
|
172
|
+
env: this.#pipeline.env,
|
|
196
173
|
mod: handler
|
|
197
174
|
});
|
|
198
175
|
} else {
|
|
@@ -224,7 +201,7 @@ class App {
|
|
|
224
201
|
route: routeData,
|
|
225
202
|
status,
|
|
226
203
|
mod,
|
|
227
|
-
env: this.#env
|
|
204
|
+
env: this.#pipeline.env
|
|
228
205
|
});
|
|
229
206
|
}
|
|
230
207
|
}
|
|
@@ -232,7 +209,7 @@ class App {
|
|
|
232
209
|
* If it is a known error code, try sending the according page (e.g. 404.astro / 500.astro).
|
|
233
210
|
* This also handles pre-rendered /404 or /500 routes
|
|
234
211
|
*/
|
|
235
|
-
async #renderError(request, {
|
|
212
|
+
async #renderError(request, { status, response: originalResponse }) {
|
|
236
213
|
const errorRouteData = matchRoute("/" + status, this.#manifestData);
|
|
237
214
|
const url = new URL(request.url);
|
|
238
215
|
if (errorRouteData) {
|
|
@@ -241,22 +218,19 @@ class App {
|
|
|
241
218
|
const response2 = await fetch(statusURL.toString());
|
|
242
219
|
return this.#mergeResponses(response2, originalResponse);
|
|
243
220
|
}
|
|
244
|
-
const finalRouteData = routeData ?? errorRouteData;
|
|
245
221
|
const mod = await this.#getModuleForRoute(errorRouteData);
|
|
246
222
|
try {
|
|
247
223
|
const newRenderContext = await this.#createRenderContext(
|
|
248
224
|
url,
|
|
249
225
|
request,
|
|
250
|
-
|
|
226
|
+
errorRouteData,
|
|
251
227
|
mod,
|
|
252
228
|
status
|
|
253
229
|
);
|
|
254
230
|
const page = await mod.page();
|
|
255
231
|
const response2 = await tryRenderRoute(
|
|
256
|
-
"page",
|
|
257
|
-
// this is hardcoded to ensure proper behavior for missing endpoints
|
|
258
232
|
newRenderContext,
|
|
259
|
-
this.#env,
|
|
233
|
+
this.#pipeline.env,
|
|
260
234
|
page
|
|
261
235
|
);
|
|
262
236
|
return this.#mergeResponses(response2, originalResponse);
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { Environment } from '../render';
|
|
2
|
+
import { Pipeline } from '../pipeline.js';
|
|
3
|
+
/**
|
|
4
|
+
* Thrown when an endpoint contains a response with the header "X-Astro-Response" === 'Not-Found'
|
|
5
|
+
*/
|
|
6
|
+
export declare class EndpointNotFoundError extends Error {
|
|
7
|
+
originalResponse: Response;
|
|
8
|
+
constructor(originalResponse: Response);
|
|
9
|
+
}
|
|
10
|
+
export declare class SSRRoutePipeline extends Pipeline {
|
|
11
|
+
#private;
|
|
12
|
+
encoder: TextEncoder;
|
|
13
|
+
constructor(env: Environment);
|
|
14
|
+
}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import mime from "mime";
|
|
2
|
+
import { attachCookiesToResponse } from "../cookies/index.js";
|
|
3
|
+
import { Pipeline } from "../pipeline.js";
|
|
4
|
+
class EndpointNotFoundError extends Error {
|
|
5
|
+
originalResponse;
|
|
6
|
+
constructor(originalResponse) {
|
|
7
|
+
super();
|
|
8
|
+
this.originalResponse = originalResponse;
|
|
9
|
+
}
|
|
10
|
+
}
|
|
11
|
+
class SSRRoutePipeline extends Pipeline {
|
|
12
|
+
encoder = new TextEncoder();
|
|
13
|
+
constructor(env) {
|
|
14
|
+
super(env);
|
|
15
|
+
this.setEndpointHandler(this.#ssrEndpointHandler);
|
|
16
|
+
}
|
|
17
|
+
// This function is responsible for handling the result coming from an endpoint.
|
|
18
|
+
async #ssrEndpointHandler(request, response) {
|
|
19
|
+
if (response.type === "response") {
|
|
20
|
+
if (response.response.headers.get("X-Astro-Response") === "Not-Found") {
|
|
21
|
+
throw new EndpointNotFoundError(response.response);
|
|
22
|
+
}
|
|
23
|
+
return response.response;
|
|
24
|
+
} else {
|
|
25
|
+
const url = new URL(request.url);
|
|
26
|
+
const headers = new Headers();
|
|
27
|
+
const mimeType = mime.getType(url.pathname);
|
|
28
|
+
if (mimeType) {
|
|
29
|
+
headers.set("Content-Type", `${mimeType};charset=utf-8`);
|
|
30
|
+
} else {
|
|
31
|
+
headers.set("Content-Type", "text/plain;charset=utf-8");
|
|
32
|
+
}
|
|
33
|
+
const bytes = response.encoding !== "binary" ? this.encoder.encode(response.body) : response.body;
|
|
34
|
+
headers.set("Content-Length", bytes.byteLength.toString());
|
|
35
|
+
const newResponse = new Response(bytes, {
|
|
36
|
+
status: 200,
|
|
37
|
+
headers
|
|
38
|
+
});
|
|
39
|
+
attachCookiesToResponse(newResponse, response.cookies);
|
|
40
|
+
return newResponse;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
export {
|
|
45
|
+
EndpointNotFoundError,
|
|
46
|
+
SSRRoutePipeline
|
|
47
|
+
};
|
package/dist/core/app/types.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import type { MarkdownRenderingOptions } from '@astrojs/markdown-remark';
|
|
2
1
|
import type { RouteData, SerializedRouteData, SSRComponentMetadata, SSRLoadedRenderer, SSRResult } from '../../@types/astro';
|
|
3
2
|
import type { SinglePageBuiltModule } from '../build/types';
|
|
4
3
|
export type ComponentPath = string;
|
|
@@ -33,7 +32,6 @@ export type SSRManifest = {
|
|
|
33
32
|
base: string;
|
|
34
33
|
compressHTML: boolean;
|
|
35
34
|
assetsPrefix?: string;
|
|
36
|
-
markdown: MarkdownRenderingOptions;
|
|
37
35
|
renderers: SSRLoadedRenderer[];
|
|
38
36
|
/**
|
|
39
37
|
* Map of directive name (e.g. `load`) to the directive script code
|
|
@@ -13,6 +13,7 @@ import {
|
|
|
13
13
|
} from "../../core/build/internal.js";
|
|
14
14
|
import {
|
|
15
15
|
isRelativePath,
|
|
16
|
+
joinPaths,
|
|
16
17
|
prependForwardSlash,
|
|
17
18
|
removeLeadingForwardSlash,
|
|
18
19
|
removeTrailingForwardSlash
|
|
@@ -303,10 +304,10 @@ function getUrlForPath(pathname, base, origin, format, routeType) {
|
|
|
303
304
|
buildPathname = base;
|
|
304
305
|
} else if (routeType === "endpoint") {
|
|
305
306
|
const buildPathRelative = removeLeadingForwardSlash(pathname);
|
|
306
|
-
buildPathname = base
|
|
307
|
+
buildPathname = joinPaths(base, buildPathRelative);
|
|
307
308
|
} else {
|
|
308
309
|
const buildPathRelative = removeTrailingForwardSlash(removeLeadingForwardSlash(pathname)) + ending;
|
|
309
|
-
buildPathname = base
|
|
310
|
+
buildPathname = joinPaths(base, buildPathRelative);
|
|
310
311
|
}
|
|
311
312
|
const url = new URL(buildPathname, origin);
|
|
312
313
|
return url;
|
|
@@ -355,7 +356,6 @@ async function generatePath(pathname, opts, gopts, manifest, onRequest) {
|
|
|
355
356
|
const env = createEnvironment({
|
|
356
357
|
adapterName: manifest.adapterName,
|
|
357
358
|
logging,
|
|
358
|
-
markdown: manifest.markdown,
|
|
359
359
|
mode: opts.mode,
|
|
360
360
|
renderers: manifest.renderers,
|
|
361
361
|
clientDirectives: manifest.clientDirectives,
|
|
@@ -390,7 +390,7 @@ async function generatePath(pathname, opts, gopts, manifest, onRequest) {
|
|
|
390
390
|
let encoding;
|
|
391
391
|
let response;
|
|
392
392
|
try {
|
|
393
|
-
response = await tryRenderRoute(
|
|
393
|
+
response = await tryRenderRoute(renderContext, env, mod, onRequest);
|
|
394
394
|
} catch (err) {
|
|
395
395
|
if (!AstroError.is(err) && !err.id && typeof err === "object") {
|
|
396
396
|
err.id = pageData.component;
|
|
@@ -444,7 +444,6 @@ function createBuildManifest(settings, internals, renderers) {
|
|
|
444
444
|
entryModules: Object.fromEntries(internals.entrySpecifierToBundleMap.entries()),
|
|
445
445
|
routes: [],
|
|
446
446
|
adapterName: "",
|
|
447
|
-
markdown: settings.config.markdown,
|
|
448
447
|
clientDirectives: settings.clientDirectives,
|
|
449
448
|
compressHTML: settings.config.compressHTML,
|
|
450
449
|
renderers,
|