Skip to content

Commit

Permalink
✨ profile page storybook 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
rkskekzzz committed Sep 30, 2023
1 parent bb8d077 commit b8da7ec
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 3 deletions.
7 changes: 6 additions & 1 deletion apps/web/.storybook/main.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
const path = require('path')
const TsconfigPathsPlugin = require('tsconfig-paths-webpack-plugin')

/** @type { import('@storybook/nextjs').StorybookConfig } */
const config = {
Expand All @@ -18,6 +18,11 @@ const config = {
},
},
],
staticDirs: ['../public'],
webpackFinal: async (config, { configType }) => {
config.resolve.plugins = [new TsconfigPathsPlugin()]
return config
},
framework: {
name: '@storybook/nextjs',
options: {},
Expand Down
3 changes: 2 additions & 1 deletion apps/web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
"storybook-dark-mode": "^3.0.1",
"storybook-tailwind-dark-mode": "^1.0.22",
"tailwindcss": "3.3.2",
"tsconfig": "*"
"tsconfig": "*",
"tsconfig-paths-webpack-plugin": "^4.1.0"
}
}
20 changes: 20 additions & 0 deletions apps/web/src/stories/pages/Profile.stories.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
import type { Meta, StoryObj } from '@storybook/react'

import { default as Profile$1 } from '../../app/profile/[id]/page'

const meta = {
title: 'Pages/Profile',
component: Profile$1,
parameters: {
nextjs: {
appDirectory: true,
},
},
} satisfies Meta<typeof Profile$1>

export default meta
type Story = StoryObj<typeof meta>

export const Profile: Story = {
args: {},
}
3 changes: 2 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit b8da7ec

Please sign in to comment.