API Docs for:
Show:

Util Class

Defined in: src/lib/util.coffee:2
Module: base-domain

utility functions

Item Index

Methods

Methods

camelize

(
  • hyphened
  • [lowerFirst=false]
)
String static

converts hyphenation to camel case

'shinout-no-macbook-pro' => 'ShinoutNoMacbookPro'
'shinout-no-macbook-pro' => 'shinoutNoMacbookPro' # if lowerFirst = true

Parameters:

  • hyphened String
  • [lowerFirst=false] Boolean optional

    make capital char lower

Returns:

String:

cameled

hyphenize

(
  • hyphened
)
String static

converts hyphenation to camel case

'ShinoutNoMacbookPro' => 'shinout-no-macbook-pro'
'ABC' => 'a-b-c' # current implementation... FIXME ?

Parameters:

  • hyphened String

Returns:

String:

cameled

requireFile

(
  • file
)
Any static

requires js file in Titanium, file-not-found-like-exception occurred in require function cannot be caught. Thus, before require function is called, check the existence of the file. File extension must be '.js' in Titanium.

Parameters:

  • file String

    name without extension

Returns:

Any:

required value