Skip to content

Commit

Permalink
add vite plugin to sveltekit
Browse files Browse the repository at this point in the history
  • Loading branch information
yannbf committed Aug 19, 2024
1 parent 7ff1345 commit 3206588
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
12 changes: 9 additions & 3 deletions code/frameworks/sveltekit/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
"exports": {
".": {
"types": "./dist/index.d.ts",
"node": "./dist/index.js",
"import": "./dist/index.mjs",
"node": "./dist/index.js",
"require": "./dist/index.js"
},
"./dist/preview.mjs": {
Expand All @@ -36,6 +36,11 @@
"types": "./dist/preset.d.ts",
"require": "./dist/preset.js"
},
"./vite": {
"types": "./dist/vite.d.ts",
"require": "./dist/vite.js",
"import": "./dist/vite.mjs"
},
"./package.json": "./package.json"
},
"main": "dist/index.js",
Expand Down Expand Up @@ -78,9 +83,10 @@
"entries": [
"./src/index.ts",
"./src/preview.ts",
"./src/preset.ts"
"./src/preset.ts",
"./src/vite.ts"
],
"platform": "node"
},
"gitHead": "e6a7fd8a655c69780bc20b9749c2699e44beae16"
}
}
5 changes: 5 additions & 0 deletions code/frameworks/sveltekit/src/vite.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import { mockSveltekitStores } from './plugins/mock-sveltekit-stores'

export const storybookSveltekitPlugin = () => {
return [mockSveltekitStores()]
}

0 comments on commit 3206588

Please sign in to comment.