mirror of
https://github.com/fluxerapp/fluxer
synced 2026-10-07 19:22:14 +09:00
refactor(imports): replace relative imports with path aliases (#2741)
This commit is contained in:
@@ -12,7 +12,7 @@ import {
|
||||
TABLE_MAX_COLUMNS,
|
||||
TABLE_MAX_IDENT_CHARS,
|
||||
TABLE_WIDE_TIER_PX,
|
||||
} from '../src/table/DocsTableMetrics.ts';
|
||||
} from '@/table/DocsTableMetrics.ts';
|
||||
import {splitTableRow} from './DocsSource.ts';
|
||||
|
||||
export {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// SPDX-License-Identifier: AGPL-3.0-or-later
|
||||
|
||||
import {checkAstroServerHealth} from '../src/server/AstroServer';
|
||||
import {docsListenHost, docsListenPort} from '../src/server/DocsConfig';
|
||||
import {checkAstroServerHealth} from '@/server/AstroServer';
|
||||
import {docsListenHost, docsListenPort} from '@/server/DocsConfig';
|
||||
|
||||
await checkAstroServerHealth({
|
||||
listenHost: docsListenHost(),
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
// SPDX-License-Identifier: AGPL-3.0-or-later
|
||||
|
||||
import {runAstroServer} from '../src/server/AstroServer';
|
||||
import {docsListenHost, docsListenPort, docsPublicEndpoint} from '../src/server/DocsConfig';
|
||||
import {runAstroServer} from '@/server/AstroServer';
|
||||
import {docsListenHost, docsListenPort, docsPublicEndpoint} from '@/server/DocsConfig';
|
||||
|
||||
await runAstroServer({
|
||||
entrypoint: new URL('../dist/server/entry.mjs', import.meta.url),
|
||||
|
||||
@@ -10,8 +10,7 @@ import {fileURLToPath} from 'node:url';
|
||||
import {parseArgs} from 'node:util';
|
||||
import {extractRoutesFromControllers} from '@fluxer/openapi/src/extractors/RouteExtractor';
|
||||
import type {OpenAPIDocument} from '@fluxer/openapi/src/OpenAPITypes';
|
||||
import {installerChecksumLine} from '../src/installer/InstallerDigest.ts';
|
||||
|
||||
import {installerChecksumLine} from '@/installer/InstallerDigest.ts';
|
||||
import {type DocsRouteHeader, readRouteHeaders} from './DocsRouteHeaders.ts';
|
||||
import {DOCS_ROOT, HTTP_METHODS, type MarkdownPage, readMarkdownPages, routeShape} from './DocsSource.ts';
|
||||
|
||||
@@ -1321,7 +1320,7 @@ console.log('self-hosting guide against deploy/self-hosting');
|
||||
const digestBearing: Array<[string, string]> = [];
|
||||
for (const endpoint of INSTALLER_ENDPOINTS) {
|
||||
const source = await readFile(fileURLToPath(new URL(`../src/pages/${endpoint}`, import.meta.url)), 'utf8');
|
||||
if (!source.includes("from '../installer/Installer'")) {
|
||||
if (!source.includes("from '@/installer/Installer'")) {
|
||||
problems.push(`src/pages/${endpoint} no longer serves the script through src/installer/Installer`);
|
||||
}
|
||||
digestBearing.push([`src/pages/${endpoint}`, source]);
|
||||
|
||||
@@ -8,7 +8,6 @@ import type {
|
||||
OpenAPISchema as SchemaNode,
|
||||
OpenAPIDocument as Spec,
|
||||
} from '@fluxer/openapi/src/OpenAPITypes';
|
||||
|
||||
import {readRouteHeaders} from './DocsRouteHeaders.ts';
|
||||
import {DOCS_ROOT, HTTP_METHODS, readMarkdownPages, routeShape, slugifyHeading, splitTableRow} from './DocsSource.ts';
|
||||
|
||||
|
||||
@@ -3,7 +3,6 @@
|
||||
import {readFile} from 'node:fs/promises';
|
||||
import path from 'node:path';
|
||||
import {fileURLToPath} from 'node:url';
|
||||
|
||||
import {DOCS_ROOT, listMarkdownFiles, slugifyHeading} from './DocsSource.ts';
|
||||
|
||||
const ASTRO_CONFIG = fileURLToPath(new URL('../astro.config.ts', import.meta.url));
|
||||
|
||||
Reference in New Issue
Block a user