Skip to content

Commit

Permalink
💄 Gloss: Silence Lint/Prettier Warning
Browse files Browse the repository at this point in the history
  • Loading branch information
dominicstop committed Jan 6, 2023
1 parent c6c72d6 commit 7348a63
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/components/ModalView/ModalView.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,10 @@ const NATIVE_PROP_KEYS = {
};

const VirtualizedListContext = React.createContext(null);

// fix for react-native 0.60
const hasScrollViewContext = ScrollView.Context?.Provider != null;
const hasScrollViewContext: boolean =
(ScrollView as any).Context?.Provider != null;

//
//
Expand Down Expand Up @@ -334,8 +336,11 @@ export class ModalView extends React.PureComponent {
>
<VirtualizedListContext.Provider value={null}>
{hasScrollViewContext ? (
// @ts-ignore
<ScrollView.Context.Provider value={null}>
{this._renderModal()}
{/*
// @ts-ignore */}
</ScrollView.Context.Provider>
) : (
this._renderModal()
Expand Down

0 comments on commit 7348a63

Please sign in to comment.