Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
R
react-native-device-info
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
放牛的园子
react-native-device-info
Commits
51d14de1
Unverified
Commit
51d14de1
authored
Feb 05, 2018
by
Mehdi Achour
Committed by
GitHub
Feb 05, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
chore: add prettier and reformat files (#309)
parent
cbbbb159
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
25 additions
and
7 deletions
+25
-7
.prettierrc.json
.prettierrc.json
+9
-0
README.md
README.md
+1
-1
deviceinfo.d.ts
deviceinfo.d.ts
+4
-2
deviceinfo.js
deviceinfo.js
+1
-1
deviceinfo.js.flow
deviceinfo.js.flow
+4
-2
package.json
package.json
+2
-1
yarn.lock
yarn.lock
+4
-0
No files found.
.prettierrc.json
0 → 100644
View file @
51d14de1
{
"useTabs"
:
false
,
"printWidth"
:
80
,
"tabWidth"
:
2
,
"singleQuote"
:
true
,
"trailingComma"
:
"es5"
,
"jsxBracketSameLine"
:
false
,
"bracketSpacing"
:
true
}
README.md
View file @
51d14de1
...
...
@@ -176,7 +176,7 @@ include ':app'
## Usage
```
js
var
DeviceInfo
=
require
(
"react-native-device-info"
);
var
DeviceInfo
=
require
(
'react-native-device-info'
);
// or import DeviceInfo from 'react-native-device-info';
```
...
...
deviceinfo.d.ts
View file @
51d14de1
// should be imported this way:
// should be imported this way:
// import * as DeviceInfo from 'react-native-device-info';
export
function
getUniqueID
():
string
;
...
...
@@ -22,7 +22,9 @@ export function getInstanceID(): string;
export
function
isEmulator
():
boolean
;
export
function
isTablet
():
boolean
;
export
function
is24Hour
():
boolean
;
export
function
isPinOrFingerprintSet
():
(
cb
:
(
isPinOrFingerprintSet
:
boolean
)
=>
void
)
=>
void
;
export
function
isPinOrFingerprintSet
():
(
cb
:
(
isPinOrFingerprintSet
:
boolean
)
=>
void
)
=>
void
;
export
function
getFirstInstallTime
():
number
;
export
function
getLastUpdateTime
():
number
;
export
function
getSerialNumber
():
string
;
...
...
deviceinfo.js
View file @
51d14de1
...
...
@@ -80,7 +80,7 @@ module.exports = {
is24Hour
:
function
()
{
return
RNDeviceInfo
.
is24Hour
;
},
isPinOrFingerprintSet
:
function
()
{
isPinOrFingerprintSet
:
function
()
{
return
RNDeviceInfo
.
isPinOrFingerprintSet
;
},
getFirstInstallTime
:
function
()
{
...
...
deviceinfo.js.flow
View file @
51d14de1
...
...
@@ -22,7 +22,9 @@ declare module.exports: {
isEmulator: () => boolean,
isTablet: () => boolean,
is24Hour: () => boolean,
isPinOrFingerprintSet: () => (cb: (isPinOrFingerprintSet: boolean) => void) => void,
isPinOrFingerprintSet: () => (
cb: (isPinOrFingerprintSet: boolean) => void
) => void,
getFirstInstallTime: () => number,
getLastUpdateTime: () => number,
getSerialNumber: () => string,
...
...
@@ -35,4 +37,4 @@ declare module.exports: {
getMaxMemory: () => number,
getTotalDiskCapacity: () => number,
getFreeDiskStorage: () => number,
}
}
;
package.json
View file @
51d14de1
...
...
@@ -31,6 +31,7 @@
],
"license"
:
"
MIT
"
,
"devDependencies"
:
{
"
np
"
:
"^2.16.0"
"
np
"
:
"^2.16.0"
,
"
prettier
"
:
"^1.10.2"
}
}
yarn.lock
View file @
51d14de1
...
...
@@ -844,6 +844,10 @@ prepend-http@^1.0.1:
version "1.0.4"
resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-1.0.4.tgz#d4f4562b0ce3696e41ac52d0e002e57a635dc6dc"
prettier@^1.10.2:
version "1.10.2"
resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.10.2.tgz#1af8356d1842276a99a5b5529c82dd9e9ad3cc93"
pseudomap@^1.0.2:
version "1.0.2"
resolved "https://registry.yarnpkg.com/pseudomap/-/pseudomap-1.0.2.tgz#f052a28da70e618917ef0a8ac34c1ae5a68286b3"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment