Skip to content

Commit

Permalink
Merge pull request #29 from lifeomic/allow-alias-for-storybook
Browse files Browse the repository at this point in the history
fix: Allow aliases for storybook
  • Loading branch information
markdlv authored Feb 12, 2023
2 parents 29493d1 + cf7dbb1 commit cd4fb51
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 8 deletions.
2 changes: 2 additions & 0 deletions example/babel.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ module.exports = {
__dirname,
'./node_modules/react-native'
),
src: '../src',
lib: '../lib',
}
}
]
Expand Down
11 changes: 4 additions & 7 deletions example/storybook/stories/AppDemo.stories.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,11 @@ import { ActivityIndicator } from 'react-native';
import { NavigationContainer } from '@react-navigation/native';
import { createNativeStackNavigator } from '@react-navigation/native-stack';
import { action } from '@storybook/addon-actions';
import {
AuthContextProvider,
useAuth,
OAuthLoginButton,
OAuthContextProvider,
SettingsScreen,
} from '../../..';
import { authConfig } from './OAuth.stories';
import { AuthContextProvider, useAuth } from 'src/hooks/useAuth';
import { OAuthContextProvider } from 'src/hooks/useOAuthFlow';
import { OAuthLoginButton } from 'src/components/OAuthLoginButton';
import SettingsScreen from 'src/screens/SettingsScreen';

storiesOf('App', module).add('demo', () => {
return (
Expand Down
4 changes: 4 additions & 0 deletions tsconfig.build.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,9 @@
"noEmit": false
},
"include": ["index.ts", "src/**/*", "lib/**/*"],
"paths": {
"src": ["./src"],
"lib": ["./lib"],
},
"exclude": ["src/**/*.test.ts", "src/**/*.test.tsx"]
}
6 changes: 5 additions & 1 deletion tsconfig.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,5 +22,9 @@
"lib/**/*",
"example/**/*",
"__mocks__/**/*"
]
],
"paths": {
"src": ["./src"],
"lib": ["./lib"],
},
}

0 comments on commit cd4fb51

Please sign in to comment.