Page MenuHomePhabricator

D10031.diff
No OneTemporary

D10031.diff

diff --git a/native/components/gesture-touchable-opacity.react.js b/native/components/gesture-touchable-opacity.react.js
--- a/native/components/gesture-touchable-opacity.react.js
+++ b/native/components/gesture-touchable-opacity.react.js
@@ -200,7 +200,7 @@
]);
const fillStyle = React.useMemo(() => {
- const result = StyleSheet.flatten(props.style);
+ const result = StyleSheet.flatten<ViewStyle>(props.style);
if (!result) {
return undefined;
}
diff --git a/native/markdown/markdown.react.js b/native/markdown/markdown.react.js
--- a/native/markdown/markdown.react.js
+++ b/native/markdown/markdown.react.js
@@ -3,7 +3,6 @@
import invariant from 'invariant';
import * as React from 'react';
import { View, Text, StyleSheet } from 'react-native';
-import type { TextStyle as FlattenedTextStyle } from 'react-native/Libraries/StyleSheet/StyleSheet.js';
import * as SimpleMarkdown from 'simple-markdown';
import { onlyEmojiRegex } from 'lib/shared/emojis.js';
@@ -53,7 +52,7 @@
) {
return style;
}
- const flattened: FlattenedTextStyle = (StyleSheet.flatten(style): any);
+ const flattened = StyleSheet.flatten<TextStyle>(style);
invariant(
flattened && typeof flattened === 'object',
`Markdown component should have style`,

File Metadata

Mime Type
text/plain
Expires
Sat, Nov 9, 2:06 AM (14 h, 57 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2447398
Default Alt Text
D10031.diff (1 KB)

Event Timeline