generate-fake-data-with-fakerjs
by Jacob Cofman
generate fake data with faker.js
// Menu: Fake// Description: generate fake data with faker.js// Author: Jacob Cofman// Twitter: @jcofmanconst faker = await npm("faker");function getMethodFakerData(method) {return Object.keys(faker[method]);}const fakerMethods = ["name","address","phone","internet","company","image","lorem","helpers","date","random","finance","hacker","system","commerce","database","animal","git","music","datatype",];const method = await arg("Select-Base-Method:", fakerMethods);const fakerBaseMethods = getMethodFakerData(method);const script = await arg("Select-Script:", fakerBaseMethods);const result = await faker[method][script]();copy(result);await arg(result);