mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-07-24 02:50:01 +00:00
Merge pull request #1972 from borisyankov/support-1.0
[WIP] support 1.0
This commit is contained in:
14958
_infrastructure/tests/typescript/1.0.0/lib.d.ts
vendored
Normal file
14958
_infrastructure/tests/typescript/1.0.0/lib.d.ts
vendored
Normal file
File diff suppressed because it is too large
Load Diff
2
_infrastructure/tests/typescript/1.0.0/tsc
Normal file
2
_infrastructure/tests/typescript/1.0.0/tsc
Normal file
@@ -0,0 +1,2 @@
|
||||
#!/usr/bin/env node
|
||||
require('./tsc.js')
|
||||
62789
_infrastructure/tests/typescript/1.0.0/tsc.js
Normal file
62789
_infrastructure/tests/typescript/1.0.0/tsc.js
Normal file
File diff suppressed because one or more lines are too long
61379
_infrastructure/tests/typescript/1.0.0/typescript.js
Normal file
61379
_infrastructure/tests/typescript/1.0.0/typescript.js
Normal file
File diff suppressed because one or more lines are too long
14
nomnom/nomnom.d.ts
vendored
14
nomnom/nomnom.d.ts
vendored
@@ -3,7 +3,10 @@
|
||||
// Definitions by: Paul Vick <https://github.com/panopticoncentral>
|
||||
// Definitions: https://github.com/borisyankov/DefinitelyTyped
|
||||
|
||||
declare module "nomnom"
|
||||
// NOTE: Extra identifier's been published is a work-around for the TypeScript 1.0.0.
|
||||
// original is here -> https://github.com/borisyankov/DefinitelyTyped/commit/9aef1ad84dc006e3d25f5e57709198e33996ba84#diff-0d78c90325d4bfb40327dcc36dcd939a
|
||||
|
||||
declare module NomnomInternal
|
||||
{
|
||||
/**
|
||||
* The command-line parser.
|
||||
@@ -137,7 +140,7 @@ declare module "nomnom"
|
||||
/**
|
||||
* The command-line parser.
|
||||
*/
|
||||
interface Parser
|
||||
export interface Parser
|
||||
{
|
||||
/**
|
||||
* Returns the parser.
|
||||
@@ -220,6 +223,9 @@ declare module "nomnom"
|
||||
*/
|
||||
parse(argv?: string[]): any;
|
||||
}
|
||||
|
||||
export = Parser;
|
||||
}
|
||||
|
||||
declare var _nomnom: NomnomInternal.Parser;
|
||||
declare module "nomnom" {
|
||||
export = _nomnom;
|
||||
}
|
||||
|
||||
@@ -20,10 +20,11 @@
|
||||
"node": ">= 0.10.0"
|
||||
},
|
||||
"scripts": {
|
||||
"test": "node ./_infrastructure/tests/runner.js --tsc-version 0.9.7 --test-changes",
|
||||
"all": "node ./_infrastructure/tests/runner.js --tsc-version 0.9.7",
|
||||
"dry": "node ./_infrastructure/tests/runner.js --tsc-version 0.9.7 --skip-tests --test-changes",
|
||||
"list": "node ./_infrastructure/tests/runner.js --tsc-version 0.9.7 --skip-tests --print-files --print-refmap",
|
||||
"test": "npm run changes",
|
||||
"changes": "node ./_infrastructure/tests/runner.js --tsc-version 1.0.0 --test-changes",
|
||||
"all": "node ./_infrastructure/tests/runner.js --tsc-version 1.0.0",
|
||||
"dry": "node ./_infrastructure/tests/runner.js --tsc-version 1.0.0 --skip-tests --test-changes",
|
||||
"list": "node ./_infrastructure/tests/runner.js --tsc-version 1.0.0 --skip-tests --print-files --print-refmap",
|
||||
"help": "node ./_infrastructure/tests/runner.js -h"
|
||||
},
|
||||
"dependencies": {
|
||||
|
||||
8
should/should.d.ts
vendored
8
should/should.d.ts
vendored
@@ -111,8 +111,8 @@ interface Internal extends ShouldInternal {
|
||||
inspect(value: any, obj: any): any;
|
||||
}
|
||||
|
||||
declare module "should" {
|
||||
export = Internal;
|
||||
}
|
||||
|
||||
declare var should: Internal;
|
||||
|
||||
declare module "should" {
|
||||
export = should;
|
||||
}
|
||||
|
||||
@@ -16,4 +16,4 @@ var req: urlrouter.ServerRequest;
|
||||
var res: urlrouter.ServerResponse;
|
||||
function next() { }
|
||||
|
||||
result(req, res, next);
|
||||
result(req, res, next);
|
||||
|
||||
120
urlrouter/urlrouter.d.ts
vendored
120
urlrouter/urlrouter.d.ts
vendored
@@ -5,65 +5,65 @@
|
||||
|
||||
/// <reference path="../node/node.d.ts" />
|
||||
|
||||
declare module "_UrlRouterInternal" {
|
||||
import http = require("http");
|
||||
|
||||
export interface ServerRequest extends http.ServerRequest {
|
||||
params: any;
|
||||
}
|
||||
|
||||
export interface ServerResponse extends http.ServerResponse {
|
||||
|
||||
}
|
||||
|
||||
export interface App {
|
||||
// https://github.com/visionmedia/node-methods/blob/master/index.js
|
||||
get(urlpattern: string, handler: HttpHandler): void;
|
||||
post(urlpattern: string, handler: HttpHandler): void;
|
||||
put(urlpattern: string, handler: HttpHandler): void;
|
||||
head(urlpattern: string, handler: HttpHandler): void;
|
||||
delete(urlpattern: string, handler: HttpHandler): void;
|
||||
options(urlpattern: string, handler: HttpHandler): void;
|
||||
trace(urlpattern: string, handler: HttpHandler): void;
|
||||
copy(urlpattern: string, handler: HttpHandler): void;
|
||||
lock(urlpattern: string, handler: HttpHandler): void;
|
||||
mkcol(urlpattern: string, handler: HttpHandler): void;
|
||||
move(urlpattern: string, handler: HttpHandler): void;
|
||||
propfind(urlpattern: string, handler: HttpHandler): void;
|
||||
proppatch(urlpattern: string, handler: HttpHandler): void;
|
||||
unlock(urlpattern: string, handler: HttpHandler): void;
|
||||
report(urlpattern: string, handler: HttpHandler): void;
|
||||
mkactivity(urlpattern: string, handler: HttpHandler): void;
|
||||
checkout(urlpattern: string, handler: HttpHandler): void;
|
||||
merge(urlpattern: string, handler: HttpHandler): void;
|
||||
"m-search"(urlpattern: string, handler: HttpHandler): void;
|
||||
notify(urlpattern: string, handler: HttpHandler): void;
|
||||
subscribe(urlpattern: string, handler: HttpHandler): void;
|
||||
unsubscribe(urlpattern: string, handler: HttpHandler): void;
|
||||
patch(urlpattern: string, handler: HttpHandler): void;
|
||||
search(urlpattern: string, handler: HttpHandler): void;
|
||||
|
||||
all(urlpattern: string, handler: HttpHandler): void;
|
||||
redirect(urlpattern: string, to: string): void;
|
||||
}
|
||||
|
||||
export interface Options {
|
||||
paramsName?: string;
|
||||
pageNotFound?: (req: ServerRequest, res: ServerResponse) => void;
|
||||
errorHandler?: (err:Error, req: ServerRequest, res: ServerResponse) => void;
|
||||
}
|
||||
|
||||
export function _UrlRouterfunc(handler: (app: App) => void, options?: any): void;
|
||||
|
||||
export interface HttpHandler {
|
||||
(req: ServerRequest, res: ServerResponse, next?: () => void): void;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
declare module "urlrouter" {
|
||||
import _UrlRouterInternal = require("_UrlRouterInternal");
|
||||
import http = require("http");
|
||||
|
||||
function _UrlRouterInternal(handler: (app: _UrlRouterInternal.App) => void): _UrlRouterInternal.HttpHandler;
|
||||
export = _UrlRouterInternal;
|
||||
}
|
||||
function UrlRouterInternal(handler:(app:UrlRouterInternal.App) => void):UrlRouterInternal.HttpHandler;
|
||||
|
||||
module UrlRouterInternal {
|
||||
|
||||
|
||||
interface ServerRequest extends http.ServerRequest {
|
||||
params: any;
|
||||
}
|
||||
|
||||
interface ServerResponse extends http.ServerResponse {
|
||||
|
||||
}
|
||||
|
||||
interface App {
|
||||
// https://github.com/visionmedia/node-methods/blob/master/index.js
|
||||
get(urlpattern:string, handler:HttpHandler): void;
|
||||
post(urlpattern:string, handler:HttpHandler): void;
|
||||
put(urlpattern:string, handler:HttpHandler): void;
|
||||
head(urlpattern:string, handler:HttpHandler): void;
|
||||
delete(urlpattern:string, handler:HttpHandler): void;
|
||||
options(urlpattern:string, handler:HttpHandler): void;
|
||||
trace(urlpattern:string, handler:HttpHandler): void;
|
||||
copy(urlpattern:string, handler:HttpHandler): void;
|
||||
lock(urlpattern:string, handler:HttpHandler): void;
|
||||
mkcol(urlpattern:string, handler:HttpHandler): void;
|
||||
move(urlpattern:string, handler:HttpHandler): void;
|
||||
propfind(urlpattern:string, handler:HttpHandler): void;
|
||||
proppatch(urlpattern:string, handler:HttpHandler): void;
|
||||
unlock(urlpattern:string, handler:HttpHandler): void;
|
||||
report(urlpattern:string, handler:HttpHandler): void;
|
||||
mkactivity(urlpattern:string, handler:HttpHandler): void;
|
||||
checkout(urlpattern:string, handler:HttpHandler): void;
|
||||
merge(urlpattern:string, handler:HttpHandler): void;
|
||||
"m-search"(urlpattern:string, handler:HttpHandler): void;
|
||||
notify(urlpattern:string, handler:HttpHandler): void;
|
||||
subscribe(urlpattern:string, handler:HttpHandler): void;
|
||||
unsubscribe(urlpattern:string, handler:HttpHandler): void;
|
||||
patch(urlpattern:string, handler:HttpHandler): void;
|
||||
search(urlpattern:string, handler:HttpHandler): void;
|
||||
|
||||
all(urlpattern:string, handler:HttpHandler): void;
|
||||
redirect(urlpattern:string, to:string): void;
|
||||
}
|
||||
|
||||
interface Options {
|
||||
paramsName?: string;
|
||||
pageNotFound?: (req:ServerRequest, res:ServerResponse) => void;
|
||||
errorHandler?: (err:Error, req:ServerRequest, res:ServerResponse) => void;
|
||||
}
|
||||
|
||||
function _UrlRouterfunc(handler:(app:App) => void, options?:any):void;
|
||||
|
||||
interface HttpHandler {
|
||||
(req:ServerRequest, res:ServerResponse, next?:() => void): void;
|
||||
}
|
||||
}
|
||||
|
||||
export = UrlRouterInternal;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user