Skip to content

Commit

Permalink
Remove flow exact object syntax {| brace pipe |} from TM example (fac…
Browse files Browse the repository at this point in the history
…ebook#41779)

Summary:
Pull Request resolved: facebook#41779

Changelog: [Internal]

`exact_by_default` (https://flow.org/en/docs/types/objects/#exact-and-inexact-object-types) is turned on - https://github.com/facebook/react-native/blob/main/.flowconfig#L40 - so we don't need these extra `|`.

Reviewed By: rshest

Differential Revision: D51803601

fbshipit-source-id: bef3699333471948330c4ae541e7a7023a7b1485
  • Loading branch information
christophpurrer authored and Othinn committed Jan 9, 2024
1 parent 6700f42 commit 356ac4a
Showing 1 changed file with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,23 +36,23 @@ export type UnionFloat = 1.44 | 2.88 | 5.76;
export type UnionString = 'One' | 'Two' | 'Three';
export type UnionObject = {value: number} | {low: string};

export type ConstantsStruct = {|
export type ConstantsStruct = {
const1: boolean,
const2: number,
const3: string,
|};
};

export type ObjectStruct = {|
export type ObjectStruct = {
a: number,
b: string,
c?: ?string,
|};
};

export type ValueStruct = {|
export type ValueStruct = {
x: number,
y: string,
z: ObjectStruct,
|};
};

export type CustomHostObject = {};

Expand Down

0 comments on commit 356ac4a

Please sign in to comment.