Skip to content

Commit

Permalink
[ci] format
Browse files Browse the repository at this point in the history
  • Loading branch information
ematipico authored and astrobot-houston committed Jun 11, 2024
1 parent 7d9aac3 commit c5152db
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
7 changes: 5 additions & 2 deletions packages/astro/src/container/pipeline.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import {
createModuleScriptElement,
createStylesheetElementSet,
} from '../core/render/ssr-element.js';
import {default404Page, DEFAULT_404_ROUTE} from '../core/routing/astro-designed-error-pages.js';
import { DEFAULT_404_ROUTE, default404Page } from '../core/routing/astro-designed-error-pages.js';

export class ContainerPipeline extends Pipeline {
/**
Expand Down Expand Up @@ -70,7 +70,10 @@ export class ContainerPipeline extends Pipeline {
return { links, styles, scripts };
}

async tryRewrite(payload: RewritePayload, request: Request): Promise<[RouteData, ComponentInstance, URL]> {
async tryRewrite(
payload: RewritePayload,
request: Request
): Promise<[RouteData, ComponentInstance, URL]> {
let foundRoute: RouteData | undefined;
// options.manifest is the actual type that contains the information
let finalUrl: URL | undefined = undefined;
Expand Down
9 changes: 6 additions & 3 deletions packages/astro/src/core/render-context.ts
Original file line number Diff line number Diff line change
Expand Up @@ -358,11 +358,14 @@ export class RenderContext {
slotValues: Record<string, any> | null
): AstroGlobal {
let astroPagePartial;
// During rewriting, we must recompute the Astro global, because we need to purge the previous params/props/etc.
// During rewriting, we must recompute the Astro global, because we need to purge the previous params/props/etc.
if (this.isRewriting) {
astroPagePartial = this.#astroPagePartial = this.createAstroPagePartial(result, astroStaticPartial);
astroPagePartial = this.#astroPagePartial = this.createAstroPagePartial(
result,
astroStaticPartial
);
} else {
// Create page partial with static partial so they can be cached together.
// Create page partial with static partial so they can be cached together.
astroPagePartial = this.#astroPagePartial ??= this.createAstroPagePartial(
result,
astroStaticPartial
Expand Down

0 comments on commit c5152db

Please sign in to comment.