Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions packages/create-twenty-app/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,7 @@
"twenty-shared": "workspace:*",
"typescript": "^5.9.3",
"vite": "^8.0.0",
"vite-plugin-dts": "^4.5.4",
"vite-tsconfig-paths": "^4.2.1"
"vite-plugin-dts": "^4.5.4"
},
"engines": {
"node": "^24.5.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
"twenty-client-sdk": "TO-BE-GENERATED",
"twenty-sdk": "TO-BE-GENERATED",
"typescript": "^5.9.3",
"vite-tsconfig-paths": "^4.2.1",
"vitest": "^3.1.1"
}
}
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import tsconfigPaths from 'vite-tsconfig-paths';
import { defineConfig } from 'vitest/config';

const TWENTY_API_URL = process.env.TWENTY_API_URL ?? 'http://localhost:2020';
Expand All @@ -11,12 +10,9 @@ process.env.TWENTY_API_URL = TWENTY_API_URL;
process.env.TWENTY_API_KEY = TWENTY_API_KEY;

export default defineConfig({
plugins: [
tsconfigPaths({
projects: ['tsconfig.spec.json'],
ignoreConfigErrors: true,
}),
],
resolve: {
tsconfigPaths: true,
},
test: {
testTimeout: 120_000,
hookTimeout: 120_000,
Expand Down
7 changes: 3 additions & 4 deletions packages/create-twenty-app/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ import fs from 'fs-extra';
import path from 'path';
import { defineConfig } from 'vite';
import dts from 'vite-plugin-dts';
import tsconfigPaths from 'vite-tsconfig-paths';
import packageJson from './package.json';
import type { PackageJson } from 'type-fest';

Expand Down Expand Up @@ -55,10 +54,10 @@ export default defineConfig(() => {
return {
root: __dirname,
cacheDir: '../../node_modules/.vite/packages/create-twenty-app',
resolve: {
tsconfigPaths: true,
},
plugins: [
tsconfigPaths({
root: __dirname,
}),
dts({ entryRoot: './src', tsconfigPath: tsConfigPath }),
copyAssetPlugin([
{
Expand Down
1 change: 0 additions & 1 deletion packages/twenty-apps/examples/hello-world/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
"twenty-client-sdk": "2.13.0",
"twenty-sdk": "2.13.0",
"typescript": "^5.9.3",
"vite-tsconfig-paths": "^4.2.1",
"vitest": "^4.0.0"
}
}
10 changes: 3 additions & 7 deletions packages/twenty-apps/examples/hello-world/vitest.config.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,9 @@
import tsconfigPaths from 'vite-tsconfig-paths';
import { defineConfig } from 'vitest/config';

export default defineConfig({
plugins: [
tsconfigPaths({
projects: ['tsconfig.spec.json'],
ignoreConfigErrors: true,
}),
],
resolve: {
tsconfigPaths: true,
},
test: {
testTimeout: 120_000,
hookTimeout: 120_000,
Expand Down
1 change: 0 additions & 1 deletion packages/twenty-apps/examples/postcard/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,6 @@
"twenty-client-sdk": "2.13.0",
"twenty-sdk": "2.13.0",
"typescript": "^5.9.3",
"vite-tsconfig-paths": "^4.2.1",
"vitest": "^4.0.0"
}
}
10 changes: 3 additions & 7 deletions packages/twenty-apps/examples/postcard/vitest.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import tsconfigPaths from 'vite-tsconfig-paths';
import { defineConfig } from 'vitest/config';

const TWENTY_API_URL = process.env.TWENTY_API_URL ?? 'http://localhost:2020';
Expand All @@ -11,12 +10,9 @@ process.env.TWENTY_API_URL = TWENTY_API_URL;
process.env.TWENTY_API_KEY = TWENTY_API_KEY;

export default defineConfig({
plugins: [
tsconfigPaths({
projects: ['tsconfig.spec.json'],
ignoreConfigErrors: true,
}),
],
resolve: {
tsconfigPaths: true,
},
test: {
testTimeout: 120_000,
hookTimeout: 120_000,
Expand Down
1 change: 0 additions & 1 deletion packages/twenty-client-sdk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@
"typescript": "^5.9.3",
"vite": "^8.0.0",
"vite-plugin-dts": "^4.5.4",
"vite-tsconfig-paths": "^4.2.1",
"vitest": "^4.1.0"
},
"engines": {
Expand Down
7 changes: 1 addition & 6 deletions packages/twenty-client-sdk/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import path from 'path';
import { defineConfig } from 'vite';
import tsconfigPaths from 'vite-tsconfig-paths';
import packageJson from './package.json';

const entries = [
Expand Down Expand Up @@ -51,15 +50,11 @@ export default defineConfig(() => {
root: __dirname,
cacheDir: '../../node_modules/.vite/packages/twenty-client-sdk',
resolve: {
tsconfigPaths: true,
alias: {
'@/': path.resolve(__dirname, 'src') + '/',
},
},
plugins: [
tsconfigPaths({
root: __dirname,
}),
],
build: {
emptyOutDir: false,
outDir: 'dist',
Expand Down
5 changes: 1 addition & 4 deletions packages/twenty-emails/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import react from '@vitejs/plugin-react-swc';
import * as path from 'path';
import { APP_LOCALES } from 'twenty-shared/translations';
import { defineConfig, type Plugin } from 'vite';
import tsconfigPaths from 'vite-tsconfig-paths';

// twenty-emails bundles its deps (the Node server that consumes it doesn't have
// @react-email et al.) but runs in Node. A plain client/lib build under Vite 8
Expand Down Expand Up @@ -41,6 +40,7 @@ export default defineConfig({
cacheDir: '../../node_modules/.vite/packages/twenty-emails',

resolve: {
tsconfigPaths: true,
alias: {
'@/': path.resolve(__dirname, 'src') + '/',
'src/': path.resolve(__dirname, 'src') + '/',
Expand All @@ -61,9 +61,6 @@ export default defineConfig({
lingui({
configPath: path.resolve(__dirname, './lingui.config.ts'),
}),
tsconfigPaths({
root: __dirname,
}),
],

build: {
Expand Down
8 changes: 1 addition & 7 deletions packages/twenty-front-component-renderer/.storybook/main.ts
Original file line number Diff line number Diff line change
@@ -1,15 +1,12 @@
import type { StorybookConfig } from '@storybook/react-vite';
import path from 'node:path';
import { fileURLToPath } from 'node:url';
import tsconfigPaths from 'vite-tsconfig-paths';

const dirname =
typeof __dirname !== 'undefined'
? __dirname
: path.dirname(fileURLToPath(import.meta.url));

const packageRoot = path.resolve(dirname, '..');

const config: StorybookConfig = {
stories: ['../src/**/*.stories.@(js|jsx|ts|tsx)'],

Expand Down Expand Up @@ -37,6 +34,7 @@ const config: StorybookConfig = {
...viteConfig,
resolve: {
...viteConfig.resolve,
tsconfigPaths: true,
alias: {
...viteConfig.resolve?.alias,
'@': path.resolve(dirname, '../src'),
Expand All @@ -55,10 +53,6 @@ const config: StorybookConfig = {
),
},
},
plugins: [
...(viteConfig.plugins ?? []),
tsconfigPaths({ root: packageRoot }),
],
optimizeDeps: {
...viteConfig.optimizeDeps,
include: [
Expand Down
3 changes: 1 addition & 2 deletions packages/twenty-front-component-renderer/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,7 @@
"twenty-sdk": "workspace:*",
"twenty-shared": "workspace:*",
"twenty-ui": "workspace:*",
"vite-plugin-dts": "^4.5.4",
"vite-tsconfig-paths": "^4.2.1"
"vite-plugin-dts": "^4.5.4"
},
"engines": {
"node": "^24.5.0",
Expand Down
7 changes: 1 addition & 6 deletions packages/twenty-front-component-renderer/vite.config.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import path from 'path';
import { type PackageJson } from 'type-fest';
import { defineConfig } from 'vite';
import tsconfigPaths from 'vite-tsconfig-paths';

import packageJson from './package.json';

Expand All @@ -11,15 +10,11 @@ export default defineConfig(() => {
cacheDir:
'../../node_modules/.vite/packages/twenty-front-component-renderer',
resolve: {
tsconfigPaths: true,
alias: {
'@/': path.resolve(__dirname, 'src') + '/',
},
},
plugins: [
tsconfigPaths({
root: __dirname,
}),
],
worker: {
format: 'iife',
rollupOptions: {
Expand Down
3 changes: 1 addition & 2 deletions packages/twenty-front/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,6 @@
"storybook-addon-mock-date": "2.0.0",
"storybook-addon-pseudo-states": "^10.3.3",
"ts-jest": "^29.1.1",
"vite-plugin-svgr": "^4.3.0",
"vite-tsconfig-paths": "^4.2.1"
"vite-plugin-svgr": "^4.3.0"
}
}
10 changes: 3 additions & 7 deletions packages/twenty-front/vite.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ import {
searchForWorkspaceRoot,
} from 'vite';
import svgr from 'vite-plugin-svgr';
import tsconfigPaths from 'vite-tsconfig-paths';

import { createWywProfilingPlugin } from 'twenty-shared/vite';

Expand Down Expand Up @@ -74,10 +73,6 @@ export default defineConfig(({ mode }) => {
react({
plugins: [['@lingui/swc-plugin', {}]],
}),
tsconfigPaths({
root: __dirname,
projects: ['tsconfig.json'],
}),
svgr(),
lingui({
configPath: path.resolve(__dirname, './lingui.config.ts'),
Expand Down Expand Up @@ -260,10 +255,11 @@ export default defineConfig(({ mode }) => {
},
},
resolve: {
tsconfigPaths: true,
alias: [
// wyw-in-js 1.x resolves modules in its CSS evaluator via vite's
// resolve.alias (it no longer picks up vite-tsconfig-paths), so the
// `@/` and `~/` tsconfig path aliases must be mirrored here.
// resolve.alias (not resolve.tsconfigPaths), so the `@/` and `~/`
// tsconfig path aliases must be mirrored here.
{ find: /^@\//, replacement: path.resolve(__dirname, 'src/modules') + '/' },
{ find: /^~\//, replacement: path.resolve(__dirname, 'src') + '/' },
{ find: 'path', replacement: 'rollup-plugin-node-polyfills/polyfills/path' },
Expand Down
1 change: 0 additions & 1 deletion packages/twenty-sdk/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@
"twenty-ui": "workspace:*",
"vite": "^8.0.0",
"vite-plugin-dts": "^4.5.4",
"vite-tsconfig-paths": "^4.2.1",
"wait-on": "^9.0.10"
},
"engines": {
Expand Down
7 changes: 1 addition & 6 deletions packages/twenty-sdk/vite.config.billing.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import path from 'path';
import { type PackageJson } from 'type-fest';
import { defineConfig } from 'vite';
import tsconfigPaths from 'vite-tsconfig-paths';

import packageJson from './package.json';

Expand All @@ -10,15 +9,11 @@ export default defineConfig(() => {
root: __dirname,
cacheDir: '../../node_modules/.vite/packages/twenty-sdk-billing',
resolve: {
tsconfigPaths: true,
alias: {
'@/': path.resolve(__dirname, 'src') + '/',
},
},
plugins: [
tsconfigPaths({
root: __dirname,
}),
],
build: {
emptyOutDir: false,
outDir: 'dist/billing',
Expand Down
7 changes: 1 addition & 6 deletions packages/twenty-sdk/vite.config.browser.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import path from 'path';
import { type PackageJson } from 'type-fest';
import { defineConfig } from 'vite';
import tsconfigPaths from 'vite-tsconfig-paths';

import packageJson from './package.json';

Expand All @@ -10,15 +9,11 @@ export default defineConfig(() => {
root: __dirname,
cacheDir: '../../node_modules/.vite/packages/twenty-sdk-browser',
resolve: {
tsconfigPaths: true,
alias: {
'@/': path.resolve(__dirname, 'src') + '/',
},
},
plugins: [
tsconfigPaths({
root: __dirname,
}),
],
build: {
emptyOutDir: false,
outDir: 'dist',
Expand Down
7 changes: 1 addition & 6 deletions packages/twenty-sdk/vite.config.define.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import path from 'path';
import { type PackageJson } from 'type-fest';
import { defineConfig } from 'vite';
import tsconfigPaths from 'vite-tsconfig-paths';

import packageJson from './package.json';

Expand All @@ -10,15 +9,11 @@ export default defineConfig(() => {
root: __dirname,
cacheDir: '../../node_modules/.vite/packages/twenty-sdk-define',
resolve: {
tsconfigPaths: true,
alias: {
'@/': path.resolve(__dirname, 'src') + '/',
},
},
plugins: [
tsconfigPaths({
root: __dirname,
}),
],
build: {
emptyOutDir: false,
outDir: 'dist/define',
Expand Down
7 changes: 1 addition & 6 deletions packages/twenty-sdk/vite.config.front-component.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import path from 'path';
import { type PackageJson } from 'type-fest';
import { defineConfig } from 'vite';
import tsconfigPaths from 'vite-tsconfig-paths';

import packageJson from './package.json';

Expand All @@ -10,15 +9,11 @@ export default defineConfig(() => {
root: __dirname,
cacheDir: '../../node_modules/.vite/packages/twenty-sdk-front-component',
resolve: {
tsconfigPaths: true,
alias: {
'@/': path.resolve(__dirname, 'src') + '/',
},
},
plugins: [
tsconfigPaths({
root: __dirname,
}),
],
build: {
emptyOutDir: false,
outDir: 'dist/front-component',
Expand Down
Loading
Loading