fix: lint failing on astro and some integrations (#3794)
* fix: lint failing on astro and some integrations * chore: fix telemetry lint * chore: fix turbo cache (thx nate) * chore: fix runtime server
This commit is contained in:
parent
515e876598
commit
c6ba6ec4d9
7 changed files with 18 additions and 17 deletions
1
.github/workflows/ci.yml
vendored
1
.github/workflows/ci.yml
vendored
|
@ -21,7 +21,6 @@ defaults:
|
|||
env:
|
||||
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
|
||||
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
|
||||
TURBO_REMOTE_ONLY: true
|
||||
FORCE_COLOR: true
|
||||
ASTRO_TELEMETRY_DISABLED: true
|
||||
|
||||
|
|
|
@ -198,6 +198,6 @@ async function throwAndExit(cmd: string, err: unknown) {
|
|||
setTimeout(exitWithErrorMessage, 400);
|
||||
// Wait for the telemetry event to send, then exit. Ignore any error.
|
||||
await telemetryPromise
|
||||
.catch((err) => debug('telemetry', `record() error: ${err.message}`))
|
||||
.catch((err2) => debug('telemetry', `record() error: ${err2.message}`))
|
||||
.then(exitWithErrorMessage);
|
||||
}
|
||||
|
|
|
@ -150,6 +150,7 @@ const createIntegration = (options: IntegrationOptions = {}): AstroIntegration =
|
|||
}
|
||||
|
||||
if (!inputBuffer) {
|
||||
// eslint-disable-next-line no-console
|
||||
console.warn(`"${transform.src}" image could not be fetched`);
|
||||
continue;
|
||||
}
|
||||
|
|
|
@ -31,8 +31,8 @@ export function createPlugin(config: AstroConfig, options: Required<IntegrationO
|
|||
return {
|
||||
name: '@astrojs/image',
|
||||
enforce: 'pre',
|
||||
configResolved(config) {
|
||||
resolvedConfig = config;
|
||||
configResolved(viteConfig) {
|
||||
resolvedConfig = viteConfig;
|
||||
},
|
||||
async resolveId(id) {
|
||||
// The virtual model redirects imports to the ImageService being used
|
||||
|
|
|
@ -71,6 +71,7 @@ const createPlugin = (options?: SitemapOptions): AstroIntegration => {
|
|||
if (config.site) {
|
||||
finalSiteUrl = new URL(config.base, config.site);
|
||||
} else {
|
||||
// eslint-disable-next-line no-console
|
||||
console.warn(
|
||||
'The Sitemap integration requires the `site` astro.config option. Skipping.'
|
||||
);
|
||||
|
|
|
@ -10,7 +10,7 @@ import { getSystemInfo, SystemInfo } from './system-info.js';
|
|||
export type AstroTelemetryOptions = { astroVersion: string; viteVersion: string };
|
||||
export type TelemetryEvent = { eventName: string; payload: Record<string, any> };
|
||||
|
||||
interface EventMeta extends SystemInfo {}
|
||||
type EventMeta = SystemInfo
|
||||
interface EventContext extends ProjectInfo {
|
||||
anonymousId: string;
|
||||
anonymousSessionId: string;
|
||||
|
|
24
packages/webapi/mod.d.ts
vendored
24
packages/webapi/mod.d.ts
vendored
|
@ -1,12 +1,12 @@
|
|||
export { pathToPosix } from './lib/utils';
|
||||
export { AbortController, AbortSignal, alert, atob, Blob, btoa, ByteLengthQueuingStrategy, cancelAnimationFrame, cancelIdleCallback, CanvasRenderingContext2D, CharacterData, clearTimeout, Comment, CountQueuingStrategy, CSSStyleSheet, CustomElementRegistry, CustomEvent, Document, DocumentFragment, DOMException, Element, Event, EventTarget, fetch, File, FormData, Headers, HTMLBodyElement, HTMLCanvasElement, HTMLDivElement, HTMLDocument, HTMLElement, HTMLHeadElement, HTMLHtmlElement, HTMLImageElement, HTMLSpanElement, HTMLStyleElement, HTMLTemplateElement, HTMLUnknownElement, Image, ImageData, IntersectionObserver, MediaQueryList, MutationObserver, Node, NodeFilter, NodeIterator, OffscreenCanvas, ReadableByteStreamController, ReadableStream, ReadableStreamBYOBReader, ReadableStreamBYOBRequest, ReadableStreamDefaultController, ReadableStreamDefaultReader, Request, requestAnimationFrame, requestIdleCallback, ResizeObserver, Response, setTimeout, ShadowRoot, structuredClone, StyleSheet, Text, TransformStream, TreeWalker, URLPattern, Window, WritableStream, WritableStreamDefaultController, WritableStreamDefaultWriter } from './mod.js';
|
||||
export declare const polyfill: {
|
||||
(target: any, options?: PolyfillOptions): any;
|
||||
internals(target: any, name: string): any;
|
||||
};
|
||||
interface PolyfillOptions {
|
||||
exclude?: string | string[];
|
||||
override?: Record<string, {
|
||||
(...args: any[]): any;
|
||||
}>;
|
||||
}
|
||||
export { pathToPosix } from './lib/utils';
|
||||
export { AbortController, AbortSignal, alert, atob, Blob, btoa, ByteLengthQueuingStrategy, cancelAnimationFrame, cancelIdleCallback, CanvasRenderingContext2D, CharacterData, clearTimeout, Comment, CountQueuingStrategy, CSSStyleSheet, CustomElementRegistry, CustomEvent, Document, DocumentFragment, DOMException, Element, Event, EventTarget, fetch, File, FormData, Headers, HTMLBodyElement, HTMLCanvasElement, HTMLDivElement, HTMLDocument, HTMLElement, HTMLHeadElement, HTMLHtmlElement, HTMLImageElement, HTMLSpanElement, HTMLStyleElement, HTMLTemplateElement, HTMLUnknownElement, Image, ImageData, IntersectionObserver, MediaQueryList, MutationObserver, Node, NodeFilter, NodeIterator, OffscreenCanvas, ReadableByteStreamController, ReadableStream, ReadableStreamBYOBReader, ReadableStreamBYOBRequest, ReadableStreamDefaultController, ReadableStreamDefaultReader, Request, requestAnimationFrame, requestIdleCallback, ResizeObserver, Response, setTimeout, ShadowRoot, structuredClone, StyleSheet, Text, TransformStream, TreeWalker, URLPattern, Window, WritableStream, WritableStreamDefaultController, WritableStreamDefaultWriter, } from './mod.js';
|
||||
export declare const polyfill: {
|
||||
(target: any, options?: PolyfillOptions): any;
|
||||
internals(target: any, name: string): any;
|
||||
};
|
||||
interface PolyfillOptions {
|
||||
exclude?: string | string[];
|
||||
override?: Record<string, {
|
||||
(...args: any[]): any;
|
||||
}>;
|
||||
}
|
Loading…
Reference in a new issue