From 83885f1d693fdb7d3ce369cc67bcd39a9755f987 Mon Sep 17 00:00:00 2001 From: Broda Noel Date: Mon, 4 Sep 2023 03:05:40 -0700 Subject: [PATCH] Update Image.d.ts (#39230) Summary: I've seen that this throws a warning: ``` ``` But this is properly working, without a warning, thus, I believe the code is allowing it: ``` ``` ## Changelog: [GENERAL] [CHANGED] - Fixed `source` in `Image` type Pull Request resolved: https://github.com/facebook/react-native/pull/39230 Test Plan: Not necessary. It's just a DOC change Reviewed By: rshest Differential Revision: D48939824 Pulled By: NickGerleman fbshipit-source-id: fca2e07b7b4d4b947e365bb9d82fcf4cea484951 --- packages/react-native/Libraries/Image/Image.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/react-native/Libraries/Image/Image.d.ts b/packages/react-native/Libraries/Image/Image.d.ts index 20b3808533f850..06dbfe24bfd04f 100644 --- a/packages/react-native/Libraries/Image/Image.d.ts +++ b/packages/react-native/Libraries/Image/Image.d.ts @@ -223,7 +223,7 @@ export interface ImagePropsBase * * The currently supported formats are png, jpg, jpeg, bmp, gif, webp (Android only), psd (iOS only). */ - source: ImageSourcePropType; + source?: ImageSourcePropType | undefined; /** * A string representing the resource identifier for the image. Similar to