mirror of
https://github.com/FlipsideCrypto/DefinitelyTyped.git
synced 2026-02-06 19:07:08 +00:00
Add Types for package react-native-base64 (#47127)
Co-authored-by: evan <evanjin@toons.kr>
This commit is contained in:
parent
537d3c1655
commit
c10f5e1dbe
12
types/react-native-base64/index.d.ts
vendored
Normal file
12
types/react-native-base64/index.d.ts
vendored
Normal file
@ -0,0 +1,12 @@
|
||||
// Type definitions for react-native-base64 0.1
|
||||
// Project: https://github.com/eranbo/react-native-base64#readme
|
||||
// Definitions by: seongjoojin <https://github.com/seongjoojin>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
interface Base64 {
|
||||
encode: (input: string) => string;
|
||||
decode: (input: string) => string;
|
||||
}
|
||||
|
||||
declare const base64: Base64;
|
||||
export = base64;
|
||||
4
types/react-native-base64/react-native-base64-tests.tsx
Normal file
4
types/react-native-base64/react-native-base64-tests.tsx
Normal file
@ -0,0 +1,4 @@
|
||||
import base64 from 'react-native-base64';
|
||||
|
||||
base64.encode('Some string to encode to base64');
|
||||
base64.decode('SW4gbXkgZXllcywgaW5kaXNwb3NlZA0KSW4gZGlzZ3Vpc2VzIG5vIG9uZSBrbm93cw0KUklQIEND==');
|
||||
21
types/react-native-base64/tsconfig.json
Normal file
21
types/react-native-base64/tsconfig.json
Normal file
@ -0,0 +1,21 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6"
|
||||
],
|
||||
"allowSyntheticDefaultImports": true,
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictNullChecks": true,
|
||||
"strictFunctionTypes": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": ["index.d.ts", "react-native-base64-tests.tsx"]
|
||||
}
|
||||
1
types/react-native-base64/tslint.json
Normal file
1
types/react-native-base64/tslint.json
Normal file
@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
Loading…
Reference in New Issue
Block a user