File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed
Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,8 @@ const config: StorybookConfig = {
2727 "@/src" : path . resolve ( __dirname , "../src" ) ,
2828 "@/e2e" : path . resolve ( __dirname , "../e2e" ) ,
2929 "@/convex" : path . resolve ( __dirname , "../convex" ) ,
30+ "convex/react" : path . resolve ( __dirname , "mocks/convex-react.ts" ) ,
31+ "convex/react-clerk" : path . resolve ( __dirname , "mocks/convex-react.ts" ) ,
3032 } ;
3133
3234 return config ;
Original file line number Diff line number Diff line change 1+ // Storybook用のconvex/reactモック
2+ // useMutation/useQuery/useActionを何もしないスタブに差し替える
3+
4+ export const useQuery = ( ) => undefined ;
5+ export const useMutation = ( ) => async ( ) => { } ;
6+ export const useAction = ( ) => async ( ) => { } ;
7+ export const useConvex = ( ) => ( { } ) ;
8+ export const useConvexConnectionState = ( ) => ( { isConnected : false } ) ;
9+ export const ConvexProvider = ( { children } : { children : React . ReactNode } ) => children ;
You can’t perform that action at this time.
0 commit comments