mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-04 06:47:03 +00:00
Merge pull request #26672 from maplerichie/ex-react-native-i18n
Added type definitions for ex-react-native-i18n
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
import I18n from 'ex-react-native-i18n';
|
||||
|
||||
I18n.defaultLocale = 'en';
|
||||
I18n.fallbacks = true;
|
||||
I18n.translations = {};
|
||||
I18n.locale = 'zh';
|
||||
|
||||
const deviceLocale: string = I18n.locale;
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
// Type definitions for ex-react-native-i18n 0.0
|
||||
// Project: https://github.com/xcarpentier/ex-react-native-i18n/
|
||||
// Definitions by: LikKee Richie <https://github.com/maplerichie>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
// TypeScript Version: 2.2
|
||||
|
||||
// Actual version for ex-react-native-i18n is 0.0.4 but 'npm run lint' doesn't allow patch version to pass
|
||||
import I18n = require("i18n-js");
|
||||
// import I18n from 'ex-react-native-i18n';
|
||||
|
||||
export default I18n;
|
||||
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"ex-react-native-i18n-tests.ts"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Reference in New Issue
Block a user