import{faker}from'@faker-js/faker';// import { faker } from '@faker-js/faker/locale/de';exportfunctioncreateRandomUser():User{return{userId:faker.datatype.uuid(),username:faker.internet.userName(),email:faker.i
ceil(Math.random() * Number.MAX_SAFE_INTEGER); } 27 changes: 22 additions & 5 deletions 27 src/simple-faker.ts Original file line numberDiff line numberDiff line change @@ -1,3 +1,4 @@ import { randomSeed } from './internal/seed'; import { DatatypeModule } from './modules/...
As you can see, datatype.number() is uniformly distributed, while helpers.benfordNumber() follows Benford's law with less than 1.5% deviation. I'm not sure if this is the best implementation/most efficient, so any feedback is appreciated. I'm also new to this so I'm not sure if thi...
* @param wordCount defaults to a random number between 3 and 10 * @param range */ // TODO @Shinigami92 2022-01-11: `range` is not in use sentence(wordCount?: number, range?: number): string { if (typeof wordCount == 'undefined') { wordCount = this.faker.datatype.number({ min:...
Original file line numberDiff line numberDiff line change @@ -986,7 +986,6 @@ _.each(dataTypes, function (dataType) { 986 986 987 987 dataTypes.postgres = require('./dialects/postgres/data-types')(dataTypes); 988 988 dataTypes.mysql = require('./dialects/mysql/data-types')(dataType...
{'dataType':$[liI11I(0x3e3,'KbbB')]});break;case Illlii[liI11I(0x14e,'N#sQ')]:lI1ili+=Illlii['WdUdz'],i1lll={'open_id':'','mix_nick':$[liI11I(0x40c,'%%J^')]||'','user_id':$[liI11I(0x164,'[ZIl')]},Il1II=Illlii['txcmF'](getSignBody,Illlii[liI11I(0x2d...
faker.seed(123); const firstRandom = faker.datatype.number(); // Setting the seed again resets the sequence. faker.seed(123); const secondRandom = faker.datatype.number(); console.log(firstRandom === secondRandom);🤝 SponsorsFaker is an MIT-licensed open source project with its ongoing...
import { faker } from '@faker-js/faker'; // import { faker } from '@faker-js/faker/locale/de'; export const USERS: User[] = []; export function createRandomUser(): User { return { userId: faker.datatype.uuid(), username: faker.internet.userName(), email: faker.internet.email(...
import{faker}from'@faker-js/faker';// import { faker } from '@faker-js/faker/locale/de';exportfunctioncreateRandomUser():User{return{userId:faker.datatype.uuid(),username:faker.internet.userName(),email:faker.internet.email(),avatar:faker.image.avatar(),password:faker.internet.password(),bi...
import{faker}from'@faker-js/faker';// import { faker } from '@faker-js/faker/locale/de';exportfunctioncreateRandomUser():User{return{userId:faker.datatype.uuid(),username:faker.internet.userName(),email:faker.internet.email(),avatar:faker.image.avatar(),password:faker.internet.password(),bi...