Skip to content

Commit

Permalink
fix: ui storybook
Browse files Browse the repository at this point in the history
  • Loading branch information
edgarkhanzadian authored and pete-watters committed Aug 20, 2024
1 parent 126f912 commit 6e2d1b2
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 8 deletions.
8 changes: 8 additions & 0 deletions packages/ui/index.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
import { registerRootComponent } from 'expo';

import App from './src/app';

// registerRootComponent calls AppRegistry.registerComponent('main', () => App);
// It also ensures that whether you load the app in Expo Go or in a native build,
// the environment is set up appropriately
registerRootComponent(App);
2 changes: 1 addition & 1 deletion packages/ui/src/.storybook-native/main.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/** @type{import("@storybook/react-native").StorybookConfig} */
export default {
stories: ['../**/*.native.stories.?(ts|tsx|js|jsx)'],
addons: ['@storybook/addon-ondevice-controls', '@storybook/addon-ondevice-actions'],
addons: [],
};
8 changes: 1 addition & 7 deletions packages/ui/src/.storybook-native/storybook.requires.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
/* do not change this file, it is auto generated by storybook. */
import '@storybook/addon-ondevice-actions/register';
import '@storybook/addon-ondevice-controls/register';
import { start } from '@storybook/react-native';

const normalizedStories = [
Expand All @@ -23,10 +21,6 @@ const normalizedStories = [
global.STORIES = normalizedStories;

export const view = start({
annotations: [
require('./preview'),
require('@storybook/react-native/dist/preview'),
require('@storybook/addon-actions/preview'),
],
annotations: [require('./preview')],
storyEntries: normalizedStories,
});

0 comments on commit 6e2d1b2

Please sign in to comment.