-
Notifications
You must be signed in to change notification settings - Fork 3
/
index.android.js
54 lines (44 loc) · 1.21 KB
/
index.android.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
import React, { PureComponent } from 'react';
import {
AppRegistry,
} from 'react-native';
import Index from './app/setup';
if (!__DEV__) {
global.console = {
info: () => {},
log: () => {},
warn: () => {},
debug: () => {},
error: () => {},
};
}
if (__DEV__) {
console.disableYellowBox = true;
// console.warn('YellowBox is disabled.');
}
// 安卓国际化 Polyfill
var areIntlLocalesSupported = require('intl-locales-supported');
var localesMyAppSupports = [
/* list locales here */
];
if (global.Intl) {
// Determine if the built-in `Intl` has the locale data we need.
if (!areIntlLocalesSupported(localesMyAppSupports)) {
// `Intl` exists, but it doesn't have the data we need, so load the
// polyfill and patch the constructors we need with the polyfill's.
var IntlPolyfill = require('intl');
Intl.NumberFormat = IntlPolyfill.NumberFormat;
Intl.DateTimeFormat = IntlPolyfill.DateTimeFormat;
}
} else {
// No `Intl`, so use and load the polyfill.
global.Intl = require('intl');
}
export default class JiraAgileApp extends PureComponent {
render() {
return (
<Index />
);
}
}
AppRegistry.registerComponent('JiraAgileApp', () => JiraAgileApp);