Skip to content

Commit

Permalink
feat: storybook 배포 github action
Browse files Browse the repository at this point in the history
  • Loading branch information
ingdaeho committed Mar 6, 2024
1 parent 92bf7e5 commit a98d458
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 8 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/chromatic.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Workflow name
name: 'Chromatic Deployment'

# Event for the workflow
on: push

# List of jobs
jobs:
test:
# Operating System
runs-on: ubuntu-latest
# Job steps
steps:
- uses: actions/checkout@v1
- run: yarn
#👇 Adds Chromatic as a step in the workflow
- uses: chromaui/action@v1
# Options required for Chromatic's GitHub Action
with:
#👇 Chromatic projectToken, see https://storybook.js.org/tutorials/intro-to-storybook/react/ko/deploy/ to obtain it
projectToken: ${{ secrets.CHROMATIC_PROJECT_TOKEN }}
token: ${{ secrets.TOKEN }}
19 changes: 11 additions & 8 deletions .storybook/main.ts
Original file line number Diff line number Diff line change
@@ -1,19 +1,22 @@
import type { StorybookConfig } from "@storybook/react-vite";
import type { StorybookConfig } from '@storybook/react-vite';

const config: StorybookConfig = {
stories: ["../src/**/*.mdx", "../src/**/*.stories.@(js|jsx|mjs|ts|tsx)"],
stories: ['../src/**/*.mdx', '../src/**/*.stories.@(js|jsx|mjs|ts|tsx)'],
addons: [
"@storybook/addon-links",
"@storybook/addon-essentials",
"@storybook/addon-onboarding",
"@storybook/addon-interactions",
'@storybook/addon-links',
'@storybook/addon-essentials',
'@storybook/addon-onboarding',
'@storybook/addon-interactions',
],
framework: {
name: "@storybook/react-vite",
name: '@storybook/react-vite',
options: {},
},
docs: {
autodocs: "tag",
autodocs: 'tag',
},
core: {
builder: '@storybook/builder-vite',
},
};
export default config;

0 comments on commit a98d458

Please sign in to comment.