[ci] format

This commit is contained in:
matthewp 2022-10-05 20:32:46 +00:00 committed by fredkbot
parent 1f890b3363
commit d22d77856b
3 changed files with 5 additions and 7 deletions

View file

@ -1,19 +1,17 @@
/* eslint-disable no-console */
import type { ComponentIterable } from './render/component';
import { SSRResult } from '../../@types/astro.js';
import { AstroJSX, isVNode } from '../../jsx-runtime/index.js';
import {
escapeHTML,
HTMLBytes,
HTMLString,
markHTMLString,
renderComponent,
RenderInstruction,
renderToString,
spreadAttributes,
voidElementNames,
} from './index.js';
import { HTMLParts } from './render/common.js';
import type { ComponentIterable } from './render/component';
const ClientOnlyPlaceholder = 'astro-client-only';

View file

@ -280,14 +280,14 @@ If you're still stuck, please open an issue on GitHub or join us at https://astr
}
if (!hydration) {
return (async function *() {
return (async function* () {
if (slotInstructions) {
yield* slotInstructions;
}
if (isPage || renderer?.name === 'astro:jsx') {
yield html;
} else {
} else {
yield markHTMLString(html.replace(/\<\/?astro-slot\>/g, ''));
}
})();

View file

@ -1,6 +1,6 @@
import type { SSRResult } from '../../../@types/astro';
import type { AstroComponentFactory } from './index';
import type { ComponentIterable } from './component';
import type { AstroComponentFactory } from './index';
import { isHTMLString } from '../escape.js';
import { createResponse } from '../response.js';
@ -32,7 +32,7 @@ async function iterableToHTMLBytes(
if (i === 0) {
if (!/<!doctype html/i.test(String(chunk))) {
parts.append('<!DOCTYPE html>\n', result);
if(onDocTypeInjection) {
if (onDocTypeInjection) {
await onDocTypeInjection(parts);
}
}