Skip to content

Style not applied to Image when using fastimage #107

@nicoladj77

Description

@nicoladj77

I created a wrapper component:

import React from 'react';
import { createImageProgress } from 'react-native-image-progress';
import ProgressBar from 'react-native-progress/Bar';
import FastImage from 'react-native-fast-image';

const Image = createImageProgress(FastImage);
const ImageWithProgress = (props) => {
  return <Image indicator={ProgressBar} style={props.style} {...props} />;
};

export default ImageWithProgress;

The issue is that style is not applied even when specified, for example here the bordrRadius is ignored, while it works correctly with FastImage

  <ImageWithProgress
    source={image}
    style={{
      height: '100%',
      width: '100%',
      resizeMode: 'cover',
      borderRadius: 20,
    }}
  />

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions