Skip to content

Commit

Permalink
feat(#358): add Chromatic (#359)
Browse files Browse the repository at this point in the history
  • Loading branch information
Decipher authored Jan 3, 2022
1 parent d25c7cd commit 13f103d
Show file tree
Hide file tree
Showing 5 changed files with 85 additions and 35 deletions.
1 change: 1 addition & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
BASE_URL=https://demo-api.druxtjs.org
API_PROXY=1

# OAuth settings - Uncomment and set value as per backend.
#OAUTH_CLIENT_ID=
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@ dist

# Nuxt storybook
.nuxt-storybook
storybook-static

# vuepress build output
.vuepress/dist
Expand Down
2 changes: 1 addition & 1 deletion nuxt.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ export default {
query: { requiredOnly: true },
},
proxy: {
api: true
api: process.env.API_PROXY === '1',
},
views: {
query: { bundleFilter: true },
Expand Down
109 changes: 77 additions & 32 deletions package-lock.json

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

7 changes: 5 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,15 @@
"version": "0.9.0",
"private": true,
"scripts": {
"dev": "nuxt",
"build": "nuxt build",
"start": "nuxt start",
"chromatic": "npx chromatic --build-script-name storybook:build",
"dev": "nuxt",
"generate": "nuxt generate",
"lint:js": "eslint --ext .js,.vue --ignore-path .gitignore .",
"lint:style": "stylelint **/*.{vue,css} --ignore-path .gitignore",
"lint": "npm run lint:js && npm run lint:style",
"start": "nuxt start",
"storybook:build": "API_PROXY=0 npx nuxt storybook build",
"storybook": "npx nuxt storybook"
},
"lint-staged": {
Expand Down Expand Up @@ -47,6 +49,7 @@
"@nuxtjs/storybook": "4.2.0",
"@nuxtjs/stylelint-module": "4.0.0",
"babel-eslint": "10.1.0",
"chromatic": "^6.3.3",
"eslint": "8.0.1",
"eslint-config-prettier": "8.3.0",
"eslint-plugin-nuxt": "2.0.0",
Expand Down

0 comments on commit 13f103d

Please sign in to comment.