motif-utils
v0.2.1
Published
Motif JavaScript Utility Library
Readme
utils
utils.dateDiff
Kind: static property of utils
| Param | Type | Description | | --- | --- | --- | | leftDate | Date | Number | String | 원래 날짜 | | rightDate | Date | Number | String | 비교할 날짜 | | unit | String | 비교 단위 |
utils.dateFormat
Kind: static property of utils
| Param | Type | Description | | --- | --- | --- | | date | Date | Number | String | 원래 날짜 | | format | String | 변환할 형식 |
Example
// Represent 11 February 2014 in middle-endian format:
var result = utils.dateFormat(new Date(2014, 1, 11), 'MM/dd/yyyy')
//=> '02/11/2014'Example
// Represent 2 July 2014 in Esperanto:
import { eoLocale } from 'date-fns/locale/eo'
var result = utils.dateForma(new Date(2014, 6, 2), "do 'de' MMMM yyyy", {
locale: eoLocale
})
//=> '2-a de julio 2014'Example
// Escape string by single quote characters:
var result = utils.dateForma(new Date(2014, 6, 2, 15), "h 'o''clock'")
//=> "3 o'clock"utils.dateISO
Kind: static property of utils
| Param | Type | Description | | --- | --- | --- | | value | Date | Number | String | 시간 데이타 |
utils.decodeSpecialChars
Kind: static property of utils
| Param | Type | Description | | --- | --- | --- | | string | String | 변환할 문자 |
utils.getBool
Kind: static property of utils
| Param | Type | Description | | --- | --- | --- | | value | any | 임의 값 |
utils.getJSON
Kind: static property of utils
| Param | Type | Description | | --- | --- | --- | | data | Object | JSON 객체 |
utils.is
Kind: static property of utils
| Param | Type | Description | | --- | --- | --- | | value | Any | 값 | | type | Types | 체크할 타입 |
utils.paging
Kind: static property of utils
| Param | Type | | --- | --- | | params | PagingParameters |
utils.parseJSON
Kind: static property of utils
| Param | Type | | --- | --- | | jsonValue | String | | defaultValue | Object |
utils.timestamp
Kind: static property of utils
utils.uuid
Kind: static property of utils
