refactor: repartition server-side and client-side code

This commit is contained in:
LIlGG
2025-10-11 18:26:07 +08:00
parent 7acc4949fb
commit e9b573a276
309 changed files with 631 additions and 962 deletions

View File

@@ -1,6 +1,6 @@
import type { ActionFunctionArgs, LoaderFunction } from '@remix-run/node';
import { json } from '@remix-run/node';
import { createScopedLogger } from '~/lib/.server/logger';
import { createScopedLogger } from '~/utils/logger';
// These are injected by Vite at build time
declare const __PKG_NAME: string;

View File

@@ -1,6 +1,6 @@
import type { ActionFunctionArgs, LoaderFunction } from '@remix-run/node';
import { json } from '@remix-run/node';
import { createScopedLogger } from '~/lib/.server/logger';
import { createScopedLogger } from '~/utils/logger';
// Only import child_process if we're not in a Cloudflare environment
let execSync: any;

View File

@@ -1,5 +1,5 @@
import { json, type LoaderFunction, type LoaderFunctionArgs } from '@remix-run/node';
import { createScopedLogger } from '~/lib/.server/logger';
import { createScopedLogger } from '~/utils/logger';
interface GitInfo {
local: {

View File

@@ -1,6 +1,6 @@
import type { ActionFunctionArgs, LoaderFunction } from '@remix-run/node';
import { json } from '@remix-run/node';
import { createScopedLogger } from '~/lib/.server/logger';
import { createScopedLogger } from '~/utils/logger';
// Only import child_process if we're not in a Cloudflare environment
let execSync: any;

View File

@@ -1,6 +1,6 @@
import type { ActionFunctionArgs, LoaderFunction } from '@remix-run/node';
import { json } from '@remix-run/node';
import { createScopedLogger } from '~/lib/.server/logger';
import { createScopedLogger } from '~/utils/logger';
// Only import child_process if we're not in a Cloudflare environment
let execSync: any;

View File

@@ -1,5 +1,5 @@
import { type ActionFunctionArgs, type LoaderFunctionArgs } from '@remix-run/node';
import { errorResponse } from '~/utils/api-response';
import { errorResponse } from '~/.server/utils/api-response';
import { appInfoAction, appInfoLoader } from './app-info.server';
import { diskAction, diskLoader } from './disk.server';
import { gitInfoLoader } from './git-info.server';