Add tslint.json and add style fixes

This commit is contained in:
Denys Sedchenko
2017-06-09 12:57:22 +03:00
parent 73546dc95f
commit df4bb363e2
2 changed files with 19 additions and 11 deletions
+12 -11
View File
@@ -1,20 +1,21 @@
// Type definitions for normalize-url v1.9.1
// Type definitions for normalize-url 1.9
// Project: https://github.com/sindresorhus/normalize-url
// Definitions by: odin3 <https://github.com/odin3>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
declare module NormalizeUrl {
interface INormalizeUrlArgs {
normalizeProtocol: boolean;
normalizeHttps: boolean;
stripFragment: boolean;
stripWWW: boolean;
removeQueryParameters: string[];
removeTrailingSlash: boolean;
removeDirectoryIndex: RegExp[];
declare namespace NormalizeUrl {
interface NormalizeUrlArgs {
normalizeProtocol?: boolean;
normalizeHttps?: boolean;
stripFragment?: boolean;
stripWWW?: boolean;
removeQueryParameters?: string[];
removeTrailingSlash?: boolean;
removeDirectoryIndex?: RegExp[];
}
function normalizeUrl(url: string, args?: INormalizeUrlArgs): string;
// tslint:disable-next-line align
function normalizeUrl(url: string, args?: NormalizeUrlArgs): string;
}
export = NormalizeUrl.normalizeUrl;
+7
View File
@@ -0,0 +1,7 @@
{
"extends": "dtslint/dt.json",
"rules": {
// This package uses the Function type, and it will take effort to fix.
"ban-types": false
}
}