Skip to content

Commit

Permalink
Merge pull request DefinitelyTyped#12658 from patsissons/jquery-deparam
Browse files Browse the repository at this point in the history
Adding jquery-deparam typings
  • Loading branch information
paulvanbrenk authored Dec 5, 2016
2 parents f0b80f7 + 8ad1e96 commit 31d40c8
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 0 deletions.
9 changes: 9 additions & 0 deletions jquery-deparam/index.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
// Type definitions for jquery-deparam v1.0.0
// Project: https://github.com/AceMetrix/jquery-deparam
// Definitions by: Pat Sissons <http://github.com/patsissons>

export as namespace deparam;

export = deparam;

declare function deparam(params: string, coerce?: boolean): any;
3 changes: 3 additions & 0 deletions jquery-deparam/jquery-deparam-tests.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
import deparam = require('jquery-deparam');

const test1 = deparam('a=A&b=B&c=C') as { a: string, b: string, c: string };
19 changes: 19 additions & 0 deletions jquery-deparam/tsconfig.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
{
"compilerOptions": {
"module": "commonjs",
"target": "es6",
"noImplicitAny": true,
"strictNullChecks": true,
"baseUrl": "../",
"typeRoots": [
"../"
],
"types": [],
"noEmit": true,
"forceConsistentCasingInFileNames": true
},
"files": [
"index.d.ts",
"jquery-deparam-tests.ts"
]
}

0 comments on commit 31d40c8

Please sign in to comment.