Skip to content

Commit 32a4bf8

Browse files
ToyboxZachnecolas
authored andcommitted
[fix] Improve Flow types of StyleSheet.create
Close #2342
1 parent 4a9bea2 commit 32a4bf8

File tree

1 file changed

+1
-1
lines changed
  • packages/react-native-web/src/exports/StyleSheet

1 file changed

+1
-1
lines changed

packages/react-native-web/src/exports/StyleSheet/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ const absoluteFill = create({ x: { ...absoluteFillObject } }).x;
6767
/**
6868
* create
6969
*/
70-
function create(styles: Object): {| [key: string]: { [key: string]: any } |} {
70+
function create<T: Object>(styles: T): $ReadOnly<T> {
7171
Object.keys(styles).forEach((key) => {
7272
const styleObj = styles[key];
7373
// Only compile at runtime if the style is not already compiled

0 commit comments

Comments
 (0)