Skip to main content

Variable: default

const default: object;

Type declaration

env

env: object;

env.getBrowser()

getBrowser: () => object;

Returns

object

firefox
firefox: boolean;
ie
ie: boolean;
safari
safari: boolean;

env.getDevice()

getDevice: () => object;

Returns

object

android
android: boolean;
ios
ios: boolean;

env.getMouseCoords()

getMouseCoords: (e) => object;

Parameters

ParameterType
eany

Returns

object

x
x: number;
y
y: number;

env.getUserAgent()

getUserAgent: () => string;

Returns

string

env.isMac()

isMac: () => boolean;

Returns

boolean

env.isPhone()

isPhone: () => boolean;

Returns

boolean

files

files: object;

files.getFileType()

getFileType: (url) => "JS" | "CSS" | "Unknown";

Parameters

ParameterType
urlany

Returns

"JS" | "CSS" | "Unknown"

files.loadFile()

loadFile: (file) => Promise<unknown>;

Parameters

ParameterType
fileany

Returns

Promise<unknown>

files.loadFiles()

loadFiles: (files) => Promise<any[]>;

Parameters

ParameterType
filesany

Returns

Promise<any[]>

funcs

funcs: object;

funcs.deepMerge()

deepMerge: <T, U>(target, source) => T & U<T, U, V>(target, middle, source) => T & U & V;

Type Parameters

Type Parameter
T
U

Parameters

ParameterType
targetT
sourceU

Returns

T & U

Type Parameters

Type Parameter
T
U
V

Parameters

ParameterType
targetT
middleU
sourceV

Returns

T & U & V

funcs.geocode()

geocode: (query, callback) => boolean;

Parameters

ParameterType
queryany
callbackany

Returns

boolean

funcs.getNestedValue()

getNestedValue: (obj, path) => any;

Parameters

ParameterType
objany
pathany

Returns

any

funcs.splitObjectAndField()

splitObjectAndField: (fields) => object;

Parameters

ParameterType
fieldsstring

Returns

object

field
field: string;
object
object: string;

funcs.throttle()

throttle: (method, delay, scope, params) => void;

Parameters

ParameterType
methodany
delayany
scopeany
paramsany

Returns

void

http

http: object;

http.handleFailedRequest()

handleFailedRequest: (response) => void;

Parameters

ParameterType
responseany

Returns

void

numbers

numbers: object;

numbers.compareVersions()

compareVersions: (v1, v2) => -1 | 0 | 1;

Parameters

ParameterType
v1any
v2any

Returns

-1 | 0 | 1

numbers.isNumber()

isNumber: (n) => boolean;

Parameters

ParameterType
nany

Returns

boolean

numbers.parseBoolean()

parseBoolean: (string) => boolean;

Parameters

ParameterType
stringany

Returns

boolean

strings

strings: object;

strings.convertToText()

convertToText: (obj) => any;

Parameters

ParameterType
objany

Returns

any

strings.fixColorHash()

fixColorHash: (color) => string;

Parameters

ParameterType
colorstring

Returns

string

strings.functionFromString

functionFromString: Object;

strings.removeLeadingSlash()

removeLeadingSlash: (str) => any;

Parameters

ParameterType
strany

Returns

any

strings.safeURL()

safeURL: (url) => any;

Parameters

ParameterType
urlany

Returns

any

strings.toSnakeCase()

toSnakeCase: (str) => string;

Parameters

ParameterType
strstring

Returns

string

strings.ucfirst()

ucfirst: (string) => any;

Parameters

ParameterType
stringany

Returns

any