Merge pull request #31191 from BendingBender/decode-uri-component

Add types for decode-uri-component
This commit is contained in:
Nathan Shively-Sanders
2018-12-17 15:49:48 -08:00
committed by GitHub
4 changed files with 44 additions and 0 deletions
@@ -0,0 +1,12 @@
import decodeUriComponent = require('decode-uri-component');
// $ExpectType string
decodeUriComponent('%25');
decodeUriComponent('%');
decodeUriComponent('st%C3%A5le');
decodeUriComponent('%st%C3%A5le%');
decodeUriComponent('%%7Bst%C3%A5le%7D%');
decodeUriComponent('%7B%ab%%7C%de%%7D');
decodeUriComponent('%FE%FF');
decodeUriComponent('%C2');
decodeUriComponent('%C2%B5');
+8
View File
@@ -0,0 +1,8 @@
// Type definitions for decode-uri-component 0.2
// Project: https://github.com/samverschueren/decode-uri-component#readme
// Definitions by: BendingBender <https://github.com/BendingBender>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
export = decodeUriComponent;
declare function decodeUriComponent(encodedURI: string): string;
+23
View File
@@ -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",
"decode-uri-component-tests.ts"
]
}
+1
View File
@@ -0,0 +1 @@
{ "extends": "dtslint/dt.json" }