0.0.42 • Published 9 months ago

fish-helper v0.0.42

Weekly downloads
-
License
MIT
Repository
-
Last release
9 months ago
npm install fish-helper
const helper = require('fish-helper')
MethodDescription
add(hour, start)Add hour from start date, return timestamp.
offset_time(date, type)The time difference (absolute value), returns the corresponding string.
before_lt_hour(date, hour)The date is less than now, and the date is less than hour from now.
before_gt_hour(date, hour)The date is less than now, and the date is greater than hour from now.
after_lt_hour(date, hour)The date is greater than now, and the date is less than hour from now.
after_gt_hour(date, hour)The date is greater than now, and the date is greater than hour from now.
is_current_year(date)Return boolean.
get_time_obj(date)Return object that includes keys: year, month, day, hour, minute, seconds, day_of_week.
format_count({num, divide, suffix, show_suffix_always})Return num or string or 0.
format_num2date(timestamp)Convert time to object; return object that includes keys: day, hour, minute, seconds.
count_down(date, fn)End time countdown, end time can be passed in by itself; fn is a callback function that takes a remaining time argument; return a function to stop the timer.
count_down_by_remain_seconds(fn, seconds)60-second countdown. Time can pass by itself.
format_thousandth(num)Format the data as a string with thousands of bits.
is_empty(data)Determines whether the data is empty.
poll(fn, minute)Execute fn function every minute, return function to stop the fn.
is_equal(a, b)Return boolean, compare a and b; a and b are any type of data.
sleep(ms)Suspend
0.0.42

9 months ago

0.0.41

1 year ago

0.0.40

1 year ago

0.0.39

1 year ago

0.0.38

1 year ago

0.0.37

2 years ago

0.0.34

2 years ago

0.0.35

2 years ago

0.0.36

2 years ago

0.0.30

2 years ago

0.0.31

2 years ago

0.0.32

2 years ago

0.0.33

2 years ago

0.0.26

2 years ago

0.0.27

2 years ago

0.0.28

2 years ago

0.0.29

2 years ago

0.0.25

2 years ago

0.0.24

2 years ago

0.0.21

2 years ago

0.0.22

2 years ago

0.0.23

2 years ago

0.0.20

2 years ago

0.0.13

3 years ago

0.0.14

3 years ago

0.0.15

3 years ago

0.0.16

3 years ago

0.0.17

2 years ago

0.0.18

2 years ago

0.0.19

2 years ago

0.0.12

3 years ago

0.0.11

3 years ago

0.0.10

3 years ago

0.0.9

3 years ago

0.0.8

3 years ago

0.0.7

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago

0.0.4

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago