Unwrap all lone ambient external modules

This commit is contained in:
Ryan Cavanaugh
2016-04-22 14:12:45 -07:00
parent fa7a5ddc9b
commit 4a433abbf4
616 changed files with 74328 additions and 75201 deletions

91
bytes/bytes.d.ts vendored
View File

@@ -3,60 +3,59 @@
// Definitions by: Zhiyuan Wang <https://github.com/danny8002/>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
declare module 'bytes' {
/**
*Convert the given value in bytes into a string.
*
* @param {number} value
* @param {{
* thousandsSeparator: [string]
* }} [options] bytes options.
*
* @returns {string}
*/
declare function bytes(value: number, options?: { thousandsSeparator: string }): string;
/**
*Parse string to an integer in bytes.
*
* @param {string} value
* @returns {number}
*/
declare function bytes(value: string): number;
declare namespace bytes {
/**
*Convert the given value in bytes into a string.
* Format the given value in bytes into a string.
*
* If the value is negative, take Math.abs(). If it is a float,
* it is rounded.
*
* @param {number} value
* @param {{
* thousandsSeparator: [string]
* }} [options] bytes options.
*
* @returns {string}
* @param {BytesFormatOptions} [options]
*/
function bytes(value: number, options?: { thousandsSeparator: string }): string;
function format(value: number, options?: { thousandsSeparator: string }): string;
/**
*Parse string to an integer in bytes.
* Just return the input number value.
*
* @param {number} value
* @return {number}
*/
function parse(value: number): number;
/**
* Parse the string value into an integer in bytes.
*
* If no unit is given, it is assumed the value is in bytes.
*
* @param {string} value
* @returns {number}
* @return {number}
*/
function bytes(value: string): number;
namespace bytes {
/**
* Format the given value in bytes into a string.
*
* If the value is negative, take Math.abs(). If it is a float,
* it is rounded.
*
* @param {number} value
* @param {BytesFormatOptions} [options]
*/
function format(value: number, options?: { thousandsSeparator: string }): string;
/**
* Just return the input number value.
*
* @param {number} value
* @return {number}
*/
function parse(value: number): number;
/**
* Parse the string value into an integer in bytes.
*
* If no unit is given, it is assumed the value is in bytes.
*
* @param {string} value
* @return {number}
*/
function parse(value: string): number;
}
export = bytes;
function parse(value: string): number;
}
export = bytes;