Skip to content

Commit 3346df4

Browse files
authored
Merge pull request #233 from KUIT-Space/infra/delete-rollup-linux-dependency
rollup ๊ด€๋ จ ์˜์กด์„ฑ ์ œ๊ฑฐ
2 parents 678e9bd + 50ea531 commit 3346df4

28 files changed

+4348
-5399
lines changed

โ€Ž.github/workflows/build.ymlโ€Ž

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,11 @@ jobs:
1515
uses: actions/setup-node@v4
1616
with:
1717
node-version: '22.11.0'
18-
cache: 'npm'
19-
20-
- name: Install dependencies
21-
run: npm ci
18+
19+
- name: Clean install
20+
run: |
21+
rm -rf node_modules package-lock.json
22+
npm install
2223
2324
- name: Build
2425
run: npm run build

โ€Ž.gitignoreโ€Ž

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,3 +28,6 @@ localhost.pem
2828
.env
2929

3030
*storybook.log
31+
32+
# cursor
33+
.cursor

โ€Ž.storybook/main.tsโ€Ž

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ const config: StorybookConfig = {
77
"@storybook/addon-essentials",
88
"@chromatic-com/storybook",
99
"@storybook/addon-interactions",
10+
"storybook-addon-remix-react-router",
1011
],
1112
framework: {
1213
name: "@storybook/react-vite",

โ€Ž.storybook/preview.tsxโ€Ž

Lines changed: 27 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,19 @@
1+
import { initialize, mswLoader } from "msw-storybook-addon";
2+
import { handlers } from "../src/mocks/handlers";
13
import type { Preview } from "@storybook/react";
2-
import React from "react";
4+
import React, { Suspense } from "react";
35
import { ThemeProvider } from "styled-components";
46
import { createGlobalStyle } from "styled-components";
57
import { theme } from "../src/styles/Theme";
68
import GlobalStyle from "../src/styles/GlobalStyles";
79
import "../src/index.css";
10+
import { withRouter } from "storybook-addon-remix-react-router";
11+
import { QueryProvider } from "../src/apis/query-provider";
12+
import GlobalErrorFallback from "../src/components/GlobalErrorFallback";
13+
import { ErrorBoundary } from "react-error-boundary";
14+
import SkeletonDetailPage from "../src/components/SkeletonDetailPage";
15+
// Initialize MSW
16+
initialize();
817

918
const StorybookStyles = createGlobalStyle`
1019
.sb-main-centered {
@@ -18,6 +27,10 @@ const StorybookStyles = createGlobalStyle`
1827

1928
const preview: Preview = {
2029
parameters: {
30+
msw: {
31+
handlers: handlers,
32+
},
33+
actions: { argTypesRegex: "^on[A-Z].*" },
2134
controls: {
2235
matchers: {
2336
color: /(background|color)$/i,
@@ -27,13 +40,21 @@ const preview: Preview = {
2740
},
2841
decorators: [
2942
(Story) => (
30-
<ThemeProvider theme={theme}>
31-
<GlobalStyle />
32-
<StorybookStyles />
33-
<Story />
34-
</ThemeProvider>
43+
<QueryProvider>
44+
<ThemeProvider theme={theme}>
45+
<GlobalStyle />
46+
<ErrorBoundary FallbackComponent={GlobalErrorFallback}>
47+
<Suspense fallback={<SkeletonDetailPage />}>
48+
<Story />
49+
</Suspense>
50+
</ErrorBoundary>
51+
</ThemeProvider>
52+
</QueryProvider>
3553
),
54+
withRouter,
3655
],
56+
// Provide the MSW addon loader globally
57+
loaders: [mswLoader],
3758
};
3859

3960
export default preview;
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
## Summary
2+
package.json์—์„œ @rollup/rollup-linux-x64-gnu์˜ optional dependency๋ฅผ ์ œ๊ฑฐํ•˜๊ณ , .gitignore์— .cursor๋ฅผ ์ถ”๊ฐ€ํ•˜์—ฌ ๊ฐœ๋ฐœ ํ™˜๊ฒฝ์˜ ์ผ๊ด€์„ฑ์„ ๋†’์˜€์Šต๋‹ˆ๋‹ค. ํ•ด๋‹น ๋ณ€๊ฒฝ ์‚ฌํ•ญ์€ feature/231-๊ฒŒ์‹œ๋ฌผ-์ƒ์„ฑ-๋ฐ-view-๊ฐœ์„  ๋ธŒ๋žœ์น˜๋ฅผ ๊ธฐ๋ฐ˜์œผ๋กœ ํ•ฉ๋‹ˆ๋‹ค.
3+
4+
5+
## PR ์œ ํ˜• ๋ฐ ์„ธ๋ถ€ ์ž‘์—… ๋‚ด์šฉ
6+
- [x] ๋นŒ๋“œ ๋ถ€๋ถ„ ํ˜น์€ ํŒจํ‚ค์ง€ ๋งค๋‹ˆ์ € ์ˆ˜์ •
7+
- [x] ํŒŒ์ผ ํ˜น์€ ํด๋”๋ช… ์ˆ˜์ • (.gitignore)
8+
9+
- package.json์˜ optionalDependencies์—์„œ `@rollup/rollup-linux-x64-gnu`๋ฅผ ์ œ๊ฑฐํ•˜์˜€์Šต๋‹ˆ๋‹ค.
10+
- .gitignore์— `.cursor`์™€ `# cursor`๋ฅผ ์ถ”๊ฐ€ํ•˜์—ฌ Cursor IDE ๊ด€๋ จ ํŒŒ์ผ์„ ๋ฌด์‹œํ•˜๋„๋ก ํ–ˆ์Šต๋‹ˆ๋‹ค.
11+
- packageManager ํ•„๋“œ๋ฅผ ์ตœ์‹  yarn ์ •๋ณด๋กœ ๊ฐฑ์‹ ํ•˜์˜€์Šต๋‹ˆ๋‹ค.
12+
13+
14+
## test ์™„๋ฃŒ ์—ฌ๋ถ€ (์„ ํƒ)
15+
๋ณ€๊ฒฝ ์‚ฌํ•ญ์ด ์ •์ƒ์ ์œผ๋กœ ๋ฐ˜์˜๋˜๋Š”์ง€ ๋กœ์ปฌ์—์„œ ํ…Œ์ŠคํŠธ ์™„๋ฃŒ
16+
17+
## ์ž‘๋™ ์Šคํฌ๋ฆฐ์ƒท (์„ ํƒ)
18+
19+
## ๋ฆฌ๋ทฐ ์š”๊ตฌ์‚ฌํ•ญ (์„ ํƒ)
20+
ํŠน์ด์‚ฌํ•ญ ์—†์Œ

0 commit comments

Comments
ย (0)