Skip to content

Commit e654f35

Browse files
junzero741claude
andcommitted
refactor: set up @private-board/shared as pnpm workspace package
- shared package.json name을 @private-board/shared로 변경 - 루트 package.json에 workspace dependency 추가 → node_modules symlink 생성 - tsconfig.base.json에서 paths 제거, frontend에 @/* alias 추가 - next.config.js에 transpilePackages 추가 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
1 parent 924b1be commit e654f35

6 files changed

Lines changed: 15 additions & 10 deletions

File tree

apps/frontend/next.config.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ const { composePlugins, withNx } = require('@nx/next');
88
**/
99
const nextConfig = {
1010
output: 'standalone',
11+
transpilePackages: ['@private-board/shared'],
1112
nx: {},
1213
};
1314

apps/frontend/tsconfig.json

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,11 @@
1616
"allowSyntheticDefaultImports": true,
1717
"forceConsistentCasingInFileNames": true,
1818
"incremental": true,
19-
"plugins": [{ "name": "next" }]
19+
"plugins": [{ "name": "next" }],
20+
"baseUrl": ".",
21+
"paths": {
22+
"@/*": ["./src/*"]
23+
}
2024
},
2125
"include": [
2226
"**/*.ts",

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"private": true,
55
"packageManager": "pnpm@8.15.5",
66
"scripts": {
7-
"dev": "nx run-many -t dev",
7+
"dev": "nx run-many -t dev,serve",
88
"build": "nx run-many -t build",
99
"test": "nx run-many -t test",
1010
"lint": "nx run-many -t lint"
@@ -57,6 +57,7 @@
5757
"@next/third-parties": "^16.1.6",
5858
"@prisma/adapter-pg": "^7.4.1",
5959
"@prisma/client": "^7.4.1",
60+
"@private-board/shared": "workspace:^",
6061
"@tailwindcss/typography": "^0.5.19",
6162
"@tiptap/extension-image": "^3.20.0",
6263
"@tiptap/extension-placeholder": "^3.20.0",

packages/shared/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
{
2-
"name": "shared",
2+
"name": "@private-board/shared",
33
"version": "0.0.1",
44
"private": true,
55
"type": "module",
6-
"main": "./src/index.js",
7-
"types": "./src/index.d.ts",
6+
"main": "./src/index.ts",
7+
"types": "./src/index.ts",
88
"dependencies": {
99
"tslib": "^2.3.0"
1010
}

pnpm-lock.yaml

Lines changed: 3 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

tsconfig.base.json

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,7 @@
1212
"lib": ["ES2021", "dom"],
1313
"strict": true,
1414
"skipLibCheck": true,
15-
"baseUrl": ".",
16-
"paths": {
17-
"@private-board/shared": ["packages/shared/src/index.ts"],
18-
"shared": ["packages/shared/src/index.ts"]
19-
}
15+
"baseUrl": "."
2016
},
2117
"exclude": ["node_modules", "tmp"]
2218
}

0 commit comments

Comments
 (0)