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
1f92d64ea3
commit
10137cd9cc
4 changed files with 6 additions and 12 deletions
|
@ -1,6 +1,6 @@
|
||||||
import { installWindowOnGlobal } from '@lit-labs/ssr/lib/dom-shim.js';
|
import { installWindowOnGlobal } from '@lit-labs/ssr/lib/dom-shim.js';
|
||||||
|
|
||||||
if(typeof fetch === 'function') {
|
if (typeof fetch === 'function') {
|
||||||
const _fetch = fetch;
|
const _fetch = fetch;
|
||||||
installWindowOnGlobal();
|
installWindowOnGlobal();
|
||||||
globalThis.fetch = window.fetch = _fetch;
|
globalThis.fetch = window.fetch = _fetch;
|
||||||
|
|
|
@ -4,8 +4,8 @@
|
||||||
* - https://github.com/apollographql/apollo-client/blob/main/src/utilities/common/responseIterator.ts
|
* - https://github.com/apollographql/apollo-client/blob/main/src/utilities/common/responseIterator.ts
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import type { Response as NodeResponse } from 'undici';
|
|
||||||
import { Readable as NodeReadableStream } from 'stream';
|
import { Readable as NodeReadableStream } from 'stream';
|
||||||
|
import type { Response as NodeResponse } from 'undici';
|
||||||
|
|
||||||
interface NodeStreamIterator<T> {
|
interface NodeStreamIterator<T> {
|
||||||
next(): Promise<IteratorResult<T, boolean | undefined>>;
|
next(): Promise<IteratorResult<T, boolean | undefined>>;
|
||||||
|
|
|
@ -75,16 +75,10 @@ const plugins = [
|
||||||
HTMLUnknownElement: ['./Element', 'HTMLUnknownElement'],
|
HTMLUnknownElement: ['./Element', 'HTMLUnknownElement'],
|
||||||
MediaQueryList: ['./MediaQueryList', 'MediaQueryList'],
|
MediaQueryList: ['./MediaQueryList', 'MediaQueryList'],
|
||||||
Node: ['./Node', 'Node'],
|
Node: ['./Node', 'Node'],
|
||||||
ReadableStream: [
|
ReadableStream: ['node:stream/web', 'ReadableStream'],
|
||||||
'node:stream/web',
|
|
||||||
'ReadableStream',
|
|
||||||
],
|
|
||||||
ShadowRoot: ['./Node', 'ShadowRoot'],
|
ShadowRoot: ['./Node', 'ShadowRoot'],
|
||||||
Window: ['./Window', 'Window'],
|
Window: ['./Window', 'Window'],
|
||||||
'globalThis.ReadableStream': [
|
'globalThis.ReadableStream': ['node:stream/web', 'ReadableStream'],
|
||||||
'node:stream/web',
|
|
||||||
'ReadableStream',
|
|
||||||
],
|
|
||||||
}),
|
}),
|
||||||
{
|
{
|
||||||
async load(id) {
|
async load(id) {
|
||||||
|
|
|
@ -7,8 +7,6 @@ import {
|
||||||
import { Event, EventTarget } from 'event-target-shim'
|
import { Event, EventTarget } from 'event-target-shim'
|
||||||
import { Blob, File } from 'fetch-blob/from.js'
|
import { Blob, File } from 'fetch-blob/from.js'
|
||||||
import { FormData } from 'formdata-polyfill/esm.min.js'
|
import { FormData } from 'formdata-polyfill/esm.min.js'
|
||||||
import * as undici from 'undici'
|
|
||||||
import { URLPattern } from 'urlpattern-polyfill'
|
|
||||||
import {
|
import {
|
||||||
ByteLengthQueuingStrategy,
|
ByteLengthQueuingStrategy,
|
||||||
CountQueuingStrategy,
|
CountQueuingStrategy,
|
||||||
|
@ -23,6 +21,8 @@ import {
|
||||||
WritableStreamDefaultController,
|
WritableStreamDefaultController,
|
||||||
WritableStreamDefaultWriter,
|
WritableStreamDefaultWriter,
|
||||||
} from 'node:stream/web'
|
} from 'node:stream/web'
|
||||||
|
import * as undici from 'undici'
|
||||||
|
import { URLPattern } from 'urlpattern-polyfill'
|
||||||
import {
|
import {
|
||||||
cancelAnimationFrame,
|
cancelAnimationFrame,
|
||||||
requestAnimationFrame,
|
requestAnimationFrame,
|
||||||
|
|
Loading…
Reference in a new issue