Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@unpourtous/react-native-image-indicator

Package Overview
Dependencies
Maintainers
3
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@unpourtous/react-native-image-indicator - npm Package Compare versions

Comparing version 1.0.1 to 1.0.2

20

CustomImage.js

@@ -32,6 +32,14 @@ /**

let source = null
if (props.source) {
if (props.source.uri) {
source = props.source
} else {
source = {uri: props.source}
}
}
this.state = {
loading: false,
progress: 0,
headIcon: {uri: props.source} || null,
headIcon: source,
thresholdReached: !props.threshold

@@ -104,6 +112,14 @@ }

loadImage (url) {
let source = null
if (props.source) {
if (props.source.uri) {
source = props.source
} else {
source = {uri: props.source}
}
}
this.setState({
loading: false,
progress: 0,
headIcon: {uri: url} || null
headIcon: source
})

@@ -110,0 +126,0 @@ }

2

example/index.ios.js

@@ -33,3 +33,3 @@ /**

style={{alignItems: 'center', justifyContent: 'center', height:300,width:300, backgroundColor: '#fdf9e6'}}
source={'https://ss3.bdstatic.com/70cFv8Sh_Q1YnxGkpoWK1HF6hhy/it/u=2527908864,2652178879&fm=23&gp=0.jpg'}
source={'https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1496148333&di=fdcac00c65ba9c75ba102380d9c27c87&imgtype=jpg&er=1&src=http%3A%2F%2Fimg2081.poco.cn%2Fmypoco%2Fmyphoto%2F20111110%2F01%2F64030449201111100118289800869654960_068.jpg'}
defaultImage={require('./images/default.jpg')}

@@ -36,0 +36,0 @@ errorImage={require('./images/error.png')}

@@ -11,3 +11,3 @@ {

"react": "^15.4.2",
"react-native": "0.40.0",
"react-native": "^0.40.0",
"@unpourtous/react-native-image-indicator": "file:../"

@@ -14,0 +14,0 @@ },

{
"name": "@unpourtous/react-native-image-indicator",
"version": "1.0.1",
"version": "1.0.2",
"description": "react native component for image with indicator and default image",

@@ -5,0 +5,0 @@ "main": "index.js",

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc