mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-06 07:47:04 +00:00
Adds type definitions for 'valid-data-url' (#36158)
Adds type definitions and tests Adds tsconfig and tslint config
This commit is contained in:
Vendored
+13
@@ -0,0 +1,13 @@
|
||||
// Type definitions for valid-data-url 2.0
|
||||
// Project: https://github.com/killmenot/valid-data-url
|
||||
// Definitions by: jgeth <https://github.com/jgeth>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
export as namespace validDataUrl;
|
||||
|
||||
declare const validDataUrl: {
|
||||
(candidate: string): boolean;
|
||||
regex: RegExp;
|
||||
};
|
||||
|
||||
export = validDataUrl;
|
||||
@@ -0,0 +1,23 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"module": "commonjs",
|
||||
"lib": [
|
||||
"es6"
|
||||
],
|
||||
"noImplicitAny": true,
|
||||
"noImplicitThis": true,
|
||||
"strictFunctionTypes": true,
|
||||
"strictNullChecks": true,
|
||||
"baseUrl": "../",
|
||||
"typeRoots": [
|
||||
"../"
|
||||
],
|
||||
"types": [],
|
||||
"noEmit": true,
|
||||
"forceConsistentCasingInFileNames": true
|
||||
},
|
||||
"files": [
|
||||
"index.d.ts",
|
||||
"valid-data-url-tests.ts"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1 @@
|
||||
{ "extends": "dtslint/dt.json" }
|
||||
@@ -0,0 +1,3 @@
|
||||
import * as validDataUrl from "valid-data-url";
|
||||
|
||||
validDataUrl("data:text/plain;base64,SGVsbG8sIFdvcmxkIQ%3D%3D");
|
||||
Reference in New Issue
Block a user