fix android release pacckage not work
This commit is contained in:
parent
cedce4832a
commit
72effbe06a
|
|
@ -1,5 +1,5 @@
|
|||
import React, { Component } from 'react';
|
||||
import { WebView, View, StyleSheet } from 'react-native';
|
||||
import { WebView, View, StyleSheet, Platform } from 'react-native';
|
||||
import renderChart from './renderChart';
|
||||
import echarts from './echarts.min';
|
||||
import PropTypes from "prop-types";
|
||||
|
|
@ -32,7 +32,7 @@ export default class App extends Component {
|
|||
backgroundColor: this.props.backgroundColor || 'transparent'
|
||||
}}
|
||||
scalesPageToFit={false}
|
||||
source={require('./tpl.html')}
|
||||
source={(Platform.OS == 'ios') ? require('./tpl.html') : {uri:'file:///android_asset/tpl.html'}}
|
||||
onMessage={event => this.props.onPress ? this.props.onPress(JSON.parse(event.nativeEvent.data)) : null}
|
||||
{...this.props}
|
||||
/>
|
||||
|
|
|
|||
Loading…
Reference in New Issue