mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
Lint fixes
This commit is contained in:
parent
4e88afacba
commit
09d6c1153b
@ -1,6 +1,4 @@
|
||||
import { Localization } from "expo-localization";
|
||||
|
||||
Localization.getLocalizationAsync().then(localization => {
|
||||
localization.locale
|
||||
});
|
||||
Localization.locale;
|
||||
Localization.getLocalizationAsync().then(localization => localization.locale);
|
||||
Localization.locale;
|
||||
|
||||
16
types/expo-localization/index.d.ts
vendored
16
types/expo-localization/index.d.ts
vendored
@ -35,39 +35,39 @@ export interface LocalizationProps {
|
||||
isRTL: boolean;
|
||||
}
|
||||
|
||||
export class Localization {
|
||||
export namespace Localization {
|
||||
/**
|
||||
* Native device language, returned in standard format. ex: `en-US`, `es-US`
|
||||
*/
|
||||
static locale: string;
|
||||
const locale: string;
|
||||
|
||||
/**
|
||||
* List of all the native languages provided by the user settings. These are returned in the order the user defines in their native settings
|
||||
*/
|
||||
static locales: string[];
|
||||
const locales: string[];
|
||||
|
||||
/**
|
||||
* Country code for your device
|
||||
*/
|
||||
static country: string | undefined;
|
||||
const country: string | undefined;
|
||||
|
||||
/**
|
||||
* A list of all the supported ISO codes
|
||||
*/
|
||||
static isoCurrencyCodes: string[] | undefined;
|
||||
const isoCurrencyCodes: string[] | undefined;
|
||||
|
||||
/**
|
||||
* The current time zone in display format. ex: `America/Los_Angeles`
|
||||
*/
|
||||
static timezone: string;
|
||||
const timezone: string;
|
||||
|
||||
/**
|
||||
* This will return `true` if the current language is Right-to-Left
|
||||
*/
|
||||
static isRTL: boolean;
|
||||
const isRTL: boolean;
|
||||
|
||||
/**
|
||||
* Android only, on iOS changing the locale settings will cause all the apps to reset
|
||||
*/
|
||||
static getLocalizationAsync(): Promise<LocalizationProps>;
|
||||
function getLocalizationAsync(): Promise<LocalizationProps>;
|
||||
}
|
||||
|
||||
@ -7,6 +7,7 @@
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user