From 60c02da48cbe72e9d75a1340cf05e06368c16ad0 Mon Sep 17 00:00:00 2001 From: iapyang Date: Wed, 4 Sep 2019 19:53:39 +0800 Subject: [PATCH] =?UTF-8?q?refactor:=20=E5=8E=BB=E6=8E=89declare?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- typescript/core/func/array.ts | 2 +- typescript/core/func/function.ts | 2 +- typescript/core/func/number.ts | 2 +- typescript/core/func/string.ts | 3 +-- 4 files changed, 4 insertions(+), 5 deletions(-) diff --git a/typescript/core/func/array.ts b/typescript/core/func/array.ts index e33481f9f..090651efc 100644 --- a/typescript/core/func/array.ts +++ b/typescript/core/func/array.ts @@ -4,7 +4,7 @@ export type _pushDistinct = (sArray: any[], obj: any) => void; export type _pushDistinctArray = (sArray: any[], array: any[]) => void; -declare type _array = { +type _array = { pushArray: _pushArray; pushDistinct: _pushDistinct; pushDistinctArray: _pushDistinctArray; diff --git a/typescript/core/func/function.ts b/typescript/core/func/function.ts index f118d19e1..592d2c106 100644 --- a/typescript/core/func/function.ts +++ b/typescript/core/func/function.ts @@ -28,7 +28,7 @@ export type _beforeFunc = (sFunc: Function, func: Function) => Function; */ export type _afterFunc = (sFunc: Function, func: Function) => Function; -declare type _function = { +type _function = { createDistinctName: _createDistinctName; getSearchResult: _getSearchResult; beforeFunc: _beforeFunc; diff --git a/typescript/core/func/number.ts b/typescript/core/func/number.ts index 7b99e5575..d82a95962 100644 --- a/typescript/core/func/number.ts +++ b/typescript/core/func/number.ts @@ -31,7 +31,7 @@ export type _mul = (num: number, arg: number) => number; */ export type _div = (num: number, arg: number) => number; -declare type _number = { +type _number = { add: _add; sub: _sub; mul: _mul; diff --git a/typescript/core/func/string.ts b/typescript/core/func/string.ts index 9be899ccd..f0f25a190 100644 --- a/typescript/core/func/string.ts +++ b/typescript/core/func/string.ts @@ -54,8 +54,7 @@ export type _perfectStart = (str: string, start: string) => string; * @return {Number[]} 子字符串在父字符串中出现的所有位置组成的数组 */ export type _allIndexOf = (str: string, sub: string) => number[]; - -declare type _string = { +type _string = { startWith: _startWith; endWith: _endWith; getQuery: _getQuery;