fix: date from integer, #125

This commit is contained in:
harttle
2019-05-12 21:03:35 +08:00
parent bef290923c
commit fdf0043b9c
6 changed files with 42 additions and 4 deletions
+4
View File
@@ -37,6 +37,10 @@ export function toValue (value: any): any {
return value instanceof Drop ? value.valueOf() : value
}
export function isNumber (value: any): value is number {
return typeof value === 'number'
}
export function toLiquid (value: any): any {
if (isFunction(value.toLiquid)) return toLiquid(value.toLiquid())
return value