Skip to content

Commit

Permalink
feat: reorder prop
Browse files Browse the repository at this point in the history
  • Loading branch information
pklatka committed Apr 19, 2024
1 parent d2e571f commit 4fa5b88
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions packages/turbo/src/VisitableView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import React, {
import {
NativeMethods,
NativeSyntheticEvent,
StyleProp,
StyleSheet,
ViewStyle,
} from 'react-native';
Expand Down Expand Up @@ -45,7 +46,6 @@ import { nextEventLoopTick } from './utils/nextEventLoopTick';
export interface Props {
url: string;
sessionHandle?: string;
style?: ViewStyle;
applicationNameForUserAgent?: string;
stradaComponents?: StradaComponent[];
pullToRefreshEnabled?: boolean;
Expand All @@ -61,6 +61,7 @@ export interface Props {
onMessage?: SessionMessageCallback;
onAlert?: OnAlert;
onConfirm?: OnConfirm;
style?: StyleProp<ViewStyle>;
}

export interface RefObject {
Expand All @@ -74,7 +75,6 @@ const VisitableView = React.forwardRef<RefObject, React.PropsWithRef<Props>>(
const {
url,
sessionHandle = 'Default',
style = styles.container,
applicationNameForUserAgent,
stradaComponents,
pullToRefreshEnabled = true,
Expand All @@ -90,6 +90,7 @@ const VisitableView = React.forwardRef<RefObject, React.PropsWithRef<Props>>(
onFormSubmissionStarted,
onFormSubmissionFinished,
onContentProcessDidTerminate,
style = styles.container,
} = props;
const visitableViewRef = useRef<
Component<RNVisitableViewProps> & NativeMethods
Expand Down Expand Up @@ -211,7 +212,6 @@ const VisitableView = React.forwardRef<RefObject, React.PropsWithRef<Props>>(
ref={visitableViewRef}
url={props.url}
sessionHandle={sessionHandle}
style={style}
applicationNameForUserAgent={resolvedApplicationNameForUserAgent}
pullToRefreshEnabled={pullToRefreshEnabled}
onError={onErrorCombinedHandlers}
Expand All @@ -226,6 +226,7 @@ const VisitableView = React.forwardRef<RefObject, React.PropsWithRef<Props>>(
onShowLoading={handleShowLoading}
onHideLoading={handleHideLoading}
onContentProcessDidTerminate={handleOnContentProcessDidTerminate}
style={style}
/>
{webViewStateComponent}
</>
Expand Down

0 comments on commit 4fa5b88

Please sign in to comment.