Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.20 preview #2508

Open
wants to merge 4 commits into
base: master
Choose a base branch
from
Open

0.20 preview #2508

wants to merge 4 commits into from

Conversation

necolas
Copy link
Owner

@necolas necolas commented Apr 10, 2023

0.20 will be focused on the "Image" milestone: https://github.com/necolas/react-native-web/milestone/18

Notes

StyleSheet runtime for compilers

babel-plugin-react-native-web has a new option legacy, which is true by default. Set it to false and the plugin will no longer rewrite any 'react-native' paths, with the exception of the StyleSheet import.

{
  "plugins": [
    [babelPluginReactNativeWeb, { "legacy": false }]
  ]
}

The StyleSheet import is rewritten to [..]/StyleSheet/runtime.

import { StyleSheet } from 'react-native'
// => import StyleSheet from 'react-native-web/dist/exports/StyleSheet/runtime'

The runtime is only StyleSheet() without create, compose, flatten, etc., support.

// errors at runtime
StyleSheet.create({})

The legacy:false option should be used only if a built-time compiler is being used to extract styles to CSS, and either inline results or error the other StyleSheet method calls React Native includes. The compiler output should follow the style object format described by the styleq runtime.

This is an experiment to add a mechanism to exclude the runtime style compiler from builds. It's open to feedback and iteration.


Changelog

New features

  • Image: support for ImageSource with headers.
  • Image: fix image caching.
  • StyleSheet: option to remove runtime compiler.

@necolas necolas added this to the 0.20: Image milestone Apr 10, 2023
@codesandbox-ci
Copy link

codesandbox-ci bot commented Apr 10, 2023

This pull request is automatically built and testable in CodeSandbox.

To see build info of the built libraries, click here or the icon next to each commit SHA.

Latest deployment of this branch, based on commit cca0fb1:

Sandbox Source
react-native-web-examples Configuration

@github-actions
Copy link

github-actions bot commented Apr 10, 2023

Size change: +0.78 kB
Total size: 122.79 kB

Filename: gzip (minify) kB size kB change % change
./packages/react-native-web/dist/exports/Image/index.js 2.85 (7.06) +0.32 (+1.04) +12.8% (+17.2%) 🔴
./packages/react-native-web/dist/modules/ImageLoader/index.js 0.94 (2.00) +0.21 (+0.43) +28.8% (+27.0%) 🔴
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedStyle.js 0.68 (2.01) +0.07 (+0.12) +11.8% (+6.3%) 🔴
./packages/react-native-web/dist/exports/StyleSheet/runtime.js 0.18 (0.27) +0.18 (+0.27) +100.0% (+100.0%) 🔴
View unchanged
Filename: gzip (minify) kB size kB change % change
./packages/react-native-web/dist/exports/AccessibilityInfo/index.js 0.47 (1.44) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/ActivityIndicator/index.js 0.83 (1.70) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Alert/index.js 0.06 (0.05) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Animated/index.js 0.08 (0.09) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Appearance/index.js 0.33 (0.59) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/AppRegistry/AppContainer.js 0.32 (0.60) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/AppRegistry/index.js 0.81 (2.20) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/AppRegistry/renderApplication.js 0.46 (0.92) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/AppState/index.js 0.58 (1.23) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/BackHandler/index.js 0.17 (0.25) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Button/index.js 0.50 (0.96) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/CheckBox/index.js 1.50 (2.94) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Clipboard/index.js 0.39 (0.72) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/createElement/index.js 0.27 (0.50) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/DeviceEventEmitter/index.js 0.10 (0.13) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Dimensions/index.js 0.62 (1.46) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Easing/index.js 0.09 (0.08) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/findNodeHandle/index.js 0.12 (0.14) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/FlatList/index.js 0.08 (0.08) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/I18nManager/index.js 0.10 (0.10) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Image/types.js 0.02 (0.00) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/ImageBackground/index.js 0.42 (0.83) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/InputAccessoryView/index.js 0.08 (0.10) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/InteractionManager/index.js 0.73 (1.85) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/InteractionManager/TaskQueue.js 0.66 (1.40) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Keyboard/index.js 0.14 (0.20) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/KeyboardAvoidingView/index.js 0.44 (0.84) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/LayoutAnimation/index.js 0.09 (0.10) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Linking/index.js 0.70 (1.44) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/LogBox/index.js 0.08 (0.09) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Modal/index.js 0.72 (1.84) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Modal/ModalAnimation.js 0.72 (1.84) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Modal/ModalContent.js 0.59 (1.17) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Modal/ModalFocusTrap.js 0.70 (1.89) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Modal/ModalPortal.js 0.28 (0.52) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/NativeEventEmitter/index.js 0.09 (0.12) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/NativeModules/index.js 0.09 (0.10) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/PanResponder/Alternative.js 0.93 (3.23) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/PanResponder/index.js 0.09 (0.09) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Picker/index.js 0.56 (1.16) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Picker/PickerItem.js 0.16 (0.20) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/PixelRatio/index.js 0.20 (0.36) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Platform/index.js 0.14 (0.14) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Pressable/index.js 1.08 (2.49) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/processColor/index.js 0.15 (0.18) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/ProgressBar/index.js 0.66 (1.31) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/RefreshControl/index.js 0.30 (0.56) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/render/index.js 0.27 (0.71) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/SafeAreaView/index.js 0.43 (0.93) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/ScrollView/index.js 3.08 (10.59) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/ScrollView/ScrollViewBase.js 0.86 (2.09) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/SectionList/index.js 0.09 (0.09) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Share/index.js 0.38 (0.74) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StatusBar/index.js 0.17 (0.29) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/compiler/createReactDOMStyle.js 1.17 (3.39) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/compiler/hash.js 0.29 (0.70) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/compiler/hyphenateStyleName.js 0.20 (0.29) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/compiler/index.js 2.34 (7.05) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/compiler/normalizeColor.js 0.24 (0.37) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/compiler/normalizeValueWithProperty.js 0.26 (0.46) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/compiler/resolveShadowValue.js 0.26 (0.52) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/compiler/unitlessNumbers.js 0.45 (0.92) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/dom/createCSSStyleSheet.js 0.29 (0.43) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/dom/createOrderedCSSStyleSheet.js 0.72 (1.43) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/dom/index.js 0.56 (1.34) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/index.js 1.10 (2.42) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/preprocess.js 1.24 (3.56) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/StyleSheet/validate.js 0.63 (1.25) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Switch/index.js 1.31 (3.32) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Text/index.js 1.66 (4.62) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Text/TextAncestorContext.js 0.09 (0.11) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Text/types.js 0.02 (0.00) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/TextInput/index.js 2.39 (6.34) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/TextInput/types.js 0.02 (0.00) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Touchable/BoundingDimensions.js 0.25 (0.48) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Touchable/ensurePositiveDelayProps.js 0.18 (0.25) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Touchable/index.js 3.17 (13.22) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Touchable/Position.js 0.19 (0.31) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/TouchableHighlight/index.js 1.06 (2.48) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/TouchableNativeFeedback/index.js 0.08 (0.10) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/TouchableOpacity/index.js 0.97 (2.14) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/TouchableWithoutFeedback/index.js 0.65 (1.49) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/UIManager/index.js 0.73 (1.42) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/unmountComponentAtNode/index.js 0.08 (0.08) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/useColorScheme/index.js 0.19 (0.27) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/useLocaleContext/index.js 0.08 (0.09) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/useWindowDimensions/index.js 0.23 (0.39) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/Vibration/index.js 0.14 (0.18) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/View/index.js 1.34 (3.69) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/View/types.js 0.02 (0.00) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/VirtualizedList/index.js 0.09 (0.10) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/exports/YellowBox/index.js 0.16 (0.21) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/index.js 0.75 (3.59) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/AccessibilityUtil/index.js 0.14 (0.33) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/AccessibilityUtil/isDisabled.js 0.12 (0.14) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/AccessibilityUtil/propsToAccessibilityComponent.js 0.40 (0.69) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/AccessibilityUtil/propsToAriaRole.js 0.24 (0.38) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/addEventListener/index.js 0.41 (0.87) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/AssetRegistry/index.js 0.10 (0.12) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/canUseDom/index.js 0.11 (0.12) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/createDOMProps/index.js 3.51 (13.68) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/dismissKeyboard/index.js 0.13 (0.17) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/forwardedProps/index.js 0.84 (2.94) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/getBoundingClientRect/index.js 0.13 (0.17) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/isSelectionValid/index.js 0.17 (0.23) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/isWebColor/index.js 0.11 (0.12) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/mergeRefs/index.js 0.26 (0.34) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/modality/index.js 1.05 (3.68) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/multiplyStyleLengthValue/index.js 0.23 (0.29) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/normalizeColor/index.js 0.23 (0.36) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/pick/index.js 0.12 (0.11) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/prefixStyles/index.js 0.12 (0.17) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/prefixStyles/static.js 0.56 (1.64) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/requestIdleCallback/index.js 0.26 (0.51) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/setValueForStyles/dangerousStyleValue.js 0.19 (0.27) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/setValueForStyles/index.js 0.20 (0.29) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/TextInputState/index.js 0.22 (0.49) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/UnimplementedView/index.js 0.26 (0.38) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/unitlessNumbers/index.js 0.45 (0.92) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useElementLayout/index.js 0.66 (1.30) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useEvent/index.js 0.25 (0.41) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useHover/index.js 0.71 (1.64) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useLayoutEffect/index.js 0.12 (0.18) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useLocale/index.js 0.27 (0.52) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useLocale/isLocaleRTL.js 0.31 (0.48) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useMergeRefs/index.js 0.17 (0.22) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/usePlatformMethods/index.js 0.21 (0.34) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/usePressEvents/index.js 0.23 (0.36) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/usePressEvents/PressResponder.js 1.93 (7.14) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useResponderEvents/createResponderEvent.js 0.74 (1.76) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useResponderEvents/index.js 0.44 (1.05) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useResponderEvents/ResponderEventTypes.js 0.34 (0.88) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useResponderEvents/ResponderSystem.js 1.88 (6.11) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useResponderEvents/ResponderTouchHistoryStore.js 1.07 (3.38) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useResponderEvents/utils.js 0.68 (1.43) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/useStable/index.js 0.19 (0.26) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/modules/warnOnce/index.js 0.13 (0.15) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/types/index.js 0.02 (0.00) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/types/styles.js 0.02 (0.00) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/hash/index.js 0.29 (0.70) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/Animated.js 0.28 (0.72) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/AnimatedEvent.js 1.10 (2.96) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/AnimatedImplementation.js 1.72 (6.27) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/AnimatedMock.js 0.77 (2.45) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/AnimatedPlatformConfig.js 0.03 (0.01) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/animations/Animation.js 0.40 (0.90) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/animations/DecayAnimation.js 0.55 (1.33) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/animations/SpringAnimation.js 1.53 (4.67) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/animations/TimingAnimation.js 0.81 (2.27) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/bezier.js 0.69 (1.43) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/components/AnimatedFlatList.js 0.23 (0.39) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/components/AnimatedImage.js 0.11 (0.18) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/components/AnimatedScrollView.js 0.23 (0.40) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/components/AnimatedSectionList.js 0.23 (0.41) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/components/AnimatedText.js 0.11 (0.18) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/components/AnimatedView.js 0.11 (0.18) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/createAnimatedComponent.js 0.37 (0.73) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/Easing.js 0.46 (1.00) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/NativeAnimatedHelper.js 2.43 (10.63) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/NativeAnimatedModule.js 0.10 (0.13) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/NativeAnimatedTurboModule.js 0.10 (0.14) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedAddition.js 0.33 (0.83) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedColor.js 1.14 (3.93) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedDiffClamp.js 0.35 (0.80) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedDivision.js 0.46 (1.22) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedInterpolation.js 1.53 (4.04) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedModulo.js 0.29 (0.65) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedMultiplication.js 0.34 (0.85) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedNode.js 0.86 (2.76) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedProps.js 0.71 (2.35) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedSubtraction.js 0.33 (0.84) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedTracking.js 0.48 (1.30) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedTransform.js 0.45 (1.33) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedValue.js 0.92 (2.94) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedValueXY.js 0.57 (1.57) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/nodes/AnimatedWithChildren.js 0.51 (1.39) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/SpringConfig.js 0.41 (0.92) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Animated/useAnimatedProps.js 0.81 (1.98) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Batchinator/index.js 0.28 (0.53) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/deepDiffer/index.js 0.28 (0.54) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/EventEmitter/NativeEventEmitter.js 0.45 (1.11) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/EventEmitter/RCTDeviceEventEmitter.js 0.08 (0.09) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/FillRateHelper/index.js 1.20 (3.44) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/FlatList/index.js 1.86 (5.82) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/infoLog/index.js 0.10 (0.09) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/JSEventLoopWatchdog/index.js 0.48 (1.10) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/LayoutAnimation/index.js 0.52 (1.23) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/PanResponder/index.js 1.06 (4.00) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/PooledClass/index.js 0.32 (0.62) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/ReactNative/ReactNativeFeatureFlags.js 0.20 (0.27) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/SectionList/index.js 0.51 (1.33) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/StaticContainer/index.js 0.19 (0.25) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/StaticRenderer/index.js 0.15 (0.20) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/TouchHistoryMath/index.js 0.39 (1.16) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/TurboModule/RCTExport.js 0.03 (0.01) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/TurboModule/TurboModuleRegistry.js 0.22 (0.30) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Types/CoreEventTypes.js 0.03 (0.01) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Utilities/clamp.js 0.09 (0.08) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Utilities/Platform.js 0.07 (0.07) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Utilities/setAndForwardRef.js 0.17 (0.22) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Utilities/useMergeRefs.js 0.21 (0.27) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/Utilities/useRefEffect.js 0.16 (0.20) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/vendor/emitter/EventEmitter.js 0.35 (0.60) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/ViewabilityHelper/index.js 1.14 (2.55) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/VirtualizedList/CellRenderMask.js 0.67 (1.44) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/VirtualizedList/ChildListCollection.js 0.49 (1.36) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/VirtualizedList/index.js 7.97 (29.17) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/VirtualizedList/StateSafePureComponent.js 0.38 (0.79) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/VirtualizedList/VirtualizedListCellRenderer.js 0.96 (2.59) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/VirtualizedList/VirtualizedListContext.js 0.46 (1.23) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/VirtualizedList/VirtualizedListProps.js 0.08 (0.08) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/VirtualizedSectionList/index.js 2.11 (6.51) 0.00 (0.00) 0.0% (0.0%)
./packages/react-native-web/dist/vendor/react-native/VirtualizeUtils/index.js 0.88 (1.58) 0.00 (0.00) 0.0% (0.0%)

compressed-size-action

Extend ImageLoader functionality to be able to work with image sources
containing headers

We preserve the existing strategy that works with image.src for cases
where source is just an uri with no headers

When sources contain headers we make a fetch request and then render a
local url for the downloaded blob (URL.createObjectURL)

Fix #1019
Fix #2268
Close #2442
If the Image component is rendered with a `null` source, and consecutively
updated with actual source url that was already loaded, it would fail to
pick up the change - `state` would be `IDLE` for a brief moment and
this would cause a small flicker when the image renders

Let's always start from IDLE state, and update `shouldDisplaySource`
condition to be based on `ImageLoader.has` cache or not

Fix #2492
@programmrz
Copy link

I would like to use the preview in my application as I would love to take advantage of the Image http headers. I'll admit im not well versed in git... how would I reference this instead of 0.19? 0.20-dev doesnt appear to change anything

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants