[ci] format

This commit is contained in:
Princesseuh 2023-07-18 00:20:47 +00:00 committed by astrobot-houston
parent f14e48098a
commit 1c85b39d38
6 changed files with 6 additions and 7 deletions

View file

@ -11,8 +11,8 @@ import {
white, white,
yellow, yellow,
} from 'kleur/colors'; } from 'kleur/colors';
import stringWidth from 'string-width';
import { fileURLToPath } from 'node:url'; import { fileURLToPath } from 'node:url';
import stringWidth from 'string-width';
export function printDiagnostic(filePath: string, text: string, diag: Diagnostic): string { export function printDiagnostic(filePath: string, text: string, diag: Diagnostic): string {
let result = []; let result = [];

View file

@ -1,8 +1,8 @@
import * as devalue from 'devalue'; import * as devalue from 'devalue';
import type fsMod from 'node:fs'; import type fsMod from 'node:fs';
import { extname } from 'node:path'; import { extname } from 'node:path';
import type { PluginContext } from 'rollup';
import { pathToFileURL } from 'node:url'; import { pathToFileURL } from 'node:url';
import type { PluginContext } from 'rollup';
import type { Plugin } from 'vite'; import type { Plugin } from 'vite';
import type { import type {
AstroConfig, AstroConfig,

View file

@ -41,8 +41,8 @@ import { callEndpoint, throwIfRedirectNotAllowed } from '../endpoint/index.js';
import { AstroError, AstroErrorData } from '../errors/index.js'; import { AstroError, AstroErrorData } from '../errors/index.js';
import { debug, info } from '../logger/core.js'; import { debug, info } from '../logger/core.js';
import { import {
RedirectSinglePageBuiltModule,
getRedirectLocationOrThrow, getRedirectLocationOrThrow,
RedirectSinglePageBuiltModule,
routeIsRedirect, routeIsRedirect,
} from '../redirects/index.js'; } from '../redirects/index.js';
import { createEnvironment, createRenderContext, tryRenderPage } from '../render/index.js'; import { createEnvironment, createRenderContext, tryRenderPage } from '../render/index.js';

View file

@ -1,11 +1,11 @@
import type { AstroConfig, AstroIntegration } from 'astro'; import type { AstroConfig, AstroIntegration } from 'astro';
import { fileURLToPath } from 'node:url';
import { import {
EnumChangefreq, EnumChangefreq,
simpleSitemapAndIndex, simpleSitemapAndIndex,
type LinkItem as LinkItemBase, type LinkItem as LinkItemBase,
type SitemapItemLoose, type SitemapItemLoose,
} from 'sitemap'; } from 'sitemap';
import { fileURLToPath } from 'node:url';
import { ZodError } from 'zod'; import { ZodError } from 'zod';
import { generateSitemap } from './generate-sitemap.js'; import { generateSitemap } from './generate-sitemap.js';

View file

@ -2,8 +2,7 @@ import type { AstroAdapter, AstroConfig, AstroIntegration, RouteData } from 'ast
import glob from 'fast-glob'; import glob from 'fast-glob';
import { basename } from 'node:path'; import { basename } from 'node:path';
import { fileURLToPath } from 'node:url'; import { fileURLToPath, pathToFileURL } from 'node:url';
import { pathToFileURL } from 'node:url';
import { import {
defaultImageConfig, defaultImageConfig,
getImageConfig, getImageConfig,

View file

@ -1,7 +1,7 @@
import { resolve as importMetaResolve } from 'import-meta-resolve'; import { resolve as importMetaResolve } from 'import-meta-resolve';
import path from 'node:path'; import path from 'node:path';
import type * as unified from 'unified';
import { pathToFileURL } from 'node:url'; import { pathToFileURL } from 'node:url';
import type * as unified from 'unified';
const cwdUrlStr = pathToFileURL(path.join(process.cwd(), 'package.json')).toString(); const cwdUrlStr = pathToFileURL(path.join(process.cwd(), 'package.json')).toString();