Namespace: module:lib/Utils

module:lib/Utils

Source:

Members

<static, constant> BEAUTIFY :boolean

Type:
  • boolean
Default Value:
  • true
Source:

<static, constant> CONSOLE_COLORS :Object

Type:
  • Object
Source:

<static, constant> CONSOLE_RESET_COLOR :string

Type:
  • string
Default Value:
  • 
Source:

Methods

<static> color(color, str) → {string}

Colorize the given string outside Reporter
Parameters:
Name Type Description
color string
str string
Source:
Returns:
Type
string

<static> extend(receiver, obj) → {Object}

Replica of jQuery extend method
Parameters:
Name Type Description
receiver Object
obj Object
Source:
Returns:
Type
Object

<static> repeatStr(str, repNum) → {string}

Replica of PHP str_repeat
Parameters:
Name Type Description
str string
repNum number
Source:
Returns:
Type
string

<static> sprintf() → {string}

Simplified replica of PHP sprintf. It works only with %(n)s search pattern
Source:
Returns:
Type
string

<static> ucfirst(str) → {string}

Replica of PHP ucfirst
Parameters:
Name Type Description
str string
Source:
Returns:
Type
string

<static> wordwrap(str, width) → {string}

Simplified replica of PHP wordwrap
Parameters:
Name Type Description
str string
width number
Source:
Returns:
Type
string

<inner> define(factory)

Override AMD `define` function for RequireJS
Parameters:
Name Type Description
factory function
Source: