Skip to main content

Date

randBetweenDate

Generate a random date between ranges.

import { randBetweenDate } from '@ngneat/falso';

randBetweenDate({ from: new Date('10/07/2020'), to: new Date() })
randBetweenDate({ from: new Date('10/07/2020'), to: new Date(), length: 10 })
Live Editor
Result
Loading...

randFrequency

Generate a random adverb for definite or indefinite frequency.

import { randFrequency } from '@ngneat/falso';

randFrequency()
randFrequency({ length: 10 })
Live Editor
Result
Loading...

randFutureDate

Generate a random future.

import { randFutureDate } from '@ngneat/falso';

randFutureDate()
randFutureDate({ length: 10 })
randFutureDate({ years: 10 }) // default is 1
Live Editor
Result
Loading...

randMonth

Generate a random month.

import { randMonth } from '@ngneat/falso';

randMonth()
randMonth({ abbreviation: true })
randMonth({ length: 10 })
Live Editor
Result
Loading...

randPastDate

Generate a random past date.

import { randPastDate } from '@ngneat/falso';

randPastDate()
randPastDate({ length: 10 })
randPastDate({ years: 2 }) // default is 1
Live Editor
Result
Loading...

randRecentDate

Generate a random recent date.

import { randRecentDate } from '@ngneat/falso';

randRecentDate()
randRecentDate({ days: 10 }) // default is 1
randRecentDate({ length: 10 })
Live Editor
Result
Loading...

randSoonDate

Generate a random soon.

import { randSoonDate } from '@ngneat/falso';

randSoonDate()
randSoonDate({ days: 5 }) // default is 1
randSoonDate({ length: 10 })
Live Editor
Result
Loading...

randWeekday

Generate a random weekday.

import { randWeekday } from '@ngneat/falso';

randWeekday()
randWeekday({ length: 10 })
Live Editor
Result
Loading...