mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-11 20:47:32 +00:00
cleanup tsconfig
This commit is contained in:
@@ -8,7 +8,6 @@ This directory contains the simplified scripts needed for managing the ZITADEL L
|
|||||||
|
|
||||||
- `package.json` - Main package file (monorepo mode with `workspace:*`)
|
- `package.json` - Main package file (monorepo mode with `workspace:*`)
|
||||||
- `package.standalone.json` - Pre-configured standalone version (uses `latest`)
|
- `package.standalone.json` - Pre-configured standalone version (uses `latest`)
|
||||||
- `tsconfig.standalone.json` - TypeScript configuration for standalone mode
|
|
||||||
- `scripts/prepare-standalone.js` - Conversion script
|
- `scripts/prepare-standalone.js` - Conversion script
|
||||||
|
|
||||||
### Generated/Temporary Files
|
### Generated/Temporary Files
|
||||||
@@ -30,7 +29,7 @@ node scripts/prepare-standalone.js [--install]
|
|||||||
**What it does:**
|
**What it does:**
|
||||||
|
|
||||||
- Copies `package.standalone.json` → `package.json`
|
- Copies `package.standalone.json` → `package.json`
|
||||||
- Copies `tsconfig.standalone.json` → `tsconfig.json`
|
- Confirms all configurations are unified and ready for standalone use
|
||||||
- Optionally runs `npm install`
|
- Optionally runs `npm install`
|
||||||
|
|
||||||
## 🚀 **Simplified Approach**
|
## 🚀 **Simplified Approach**
|
||||||
|
@@ -9,11 +9,7 @@ import fs from 'fs/promises';
|
|||||||
import { execSync } from 'child_process';
|
import { execSync } from 'child_process';
|
||||||
|
|
||||||
const CONFIG_FILES = [
|
const CONFIG_FILES = [
|
||||||
{
|
// TypeScript config is now unified - no separate standalone version needed
|
||||||
source: 'tsconfig.standalone.json',
|
|
||||||
target: 'tsconfig.json',
|
|
||||||
required: true
|
|
||||||
}
|
|
||||||
];
|
];
|
||||||
|
|
||||||
async function prepareStandalone() {
|
async function prepareStandalone() {
|
||||||
@@ -39,28 +35,7 @@ async function prepareStandalone() {
|
|||||||
throw new Error('package.standalone.json not found!');
|
throw new Error('package.standalone.json not found!');
|
||||||
}
|
}
|
||||||
|
|
||||||
// Step 2: Copy TypeScript configuration
|
// Step 2: Install dependencies if requested
|
||||||
console.log('\n⚙️ Setting up TypeScript configuration...');
|
|
||||||
for (const config of CONFIG_FILES) {
|
|
||||||
try {
|
|
||||||
const sourceExists = await fs.access(config.source).then(() => true).catch(() => false);
|
|
||||||
if (sourceExists) {
|
|
||||||
await fs.copyFile(config.source, config.target);
|
|
||||||
console.log(` ✅ ${config.source} → ${config.target}`);
|
|
||||||
} else if (config.required) {
|
|
||||||
throw new Error(`Required file ${config.source} not found!`);
|
|
||||||
} else {
|
|
||||||
console.log(` ⚠️ ${config.source} not found, skipping`);
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
if (config.required) {
|
|
||||||
throw error;
|
|
||||||
}
|
|
||||||
console.warn(` ❌ Failed to copy ${config.source}: ${error.message}`);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Step 3: Install dependencies if requested
|
|
||||||
if (shouldInstall) {
|
if (shouldInstall) {
|
||||||
console.log('\n📥 Installing dependencies...');
|
console.log('\n📥 Installing dependencies...');
|
||||||
try {
|
try {
|
||||||
|
@@ -1,27 +0,0 @@
|
|||||||
{
|
|
||||||
"compilerOptions": {
|
|
||||||
"target": "es5",
|
|
||||||
"lib": ["dom", "dom.iterable", "esnext"],
|
|
||||||
"allowJs": true,
|
|
||||||
"skipLibCheck": true,
|
|
||||||
"strict": true,
|
|
||||||
"noEmit": true,
|
|
||||||
"esModuleInterop": true,
|
|
||||||
"module": "esnext",
|
|
||||||
"moduleResolution": "bundler",
|
|
||||||
"resolveJsonModule": true,
|
|
||||||
"isolatedModules": true,
|
|
||||||
"jsx": "preserve",
|
|
||||||
"incremental": true,
|
|
||||||
"plugins": [
|
|
||||||
{
|
|
||||||
"name": "next"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"paths": {
|
|
||||||
"@/*": ["./src/*"]
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
|
|
||||||
"exclude": ["node_modules"]
|
|
||||||
}
|
|
Reference in New Issue
Block a user