diff options
Diffstat (limited to 'README.md')
| -rw-r--r-- | README.md | 46 |
1 files changed, 24 insertions, 22 deletions
@@ -19,6 +19,8 @@ [](https://fakerjs.dev/new) +[API Documentation](https://fakerjs.dev/guide/) + ## Installation Please replace your `faker` dependency with `@faker-js/faker`. This is the official, stable fork of Faker. @@ -117,28 +119,28 @@ declare module '@faker-js/faker' { An in-depth overview of the API methods is available in the [documentation](https://fakerjs.dev/guide/). The API covers the following modules: -| Module | Example | Output | -| -------- | ------------------------------ | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| Address | `faker.address.city()` | Lake Raoulfort | -| Animal | `faker.animal.type()` | Dog, cat, snake, bear, lion, etc. | -| Commerce | `faker.commerce.product()` | Polo t-shirt | -| Company | `faker.company.companyName()` | Zboncak and Sons | -| Database | `faker.database.engine()` | MyISAM | -| Datatype | `faker.datatype.uuid()` | 7b16dd12-935e-4acc-8381-b1e457bf0176 | -| Date | `faker.date.past()` | Sat Oct 20 2018 04:19:38 GMT-0700 (Pacific Daylight Time) | -| Finance | `faker.finance.amount()` | ¥23400 (After setting locale) | -| Git | `faker.git.commitMessage()` | feat: add products list page | -| Hacker | `faker.hacker.phrase()` | Try to reboot the SQL bus, maybe it will bypass the virtual application! | -| Helpers | `faker.helpers.userCard()` | `{ avatar: '...', email: '{ first }{ last }{ number }@{domain}', first: '...' }`<br/><br/>All of the values are self-consistent (e.g. same first + last name in the email, too) | -| Image | `faker.image.avatar()` | `https://cloudflare-ipfs.com/ipfs/Qmd3W5DuhgHirLHGVixi6V76LhCkZUz6pnFt5AJBiyvHye/avatar/233.jpg` <img src="https://cloudflare-ipfs.com/ipfs/Qmd3W5DuhgHirLHGVixi6V76LhCkZUz6pnFt5AJBiyvHye/avatar/233.jpg" width="64"/> | -| Internet | `faker.internet.color()` | #630c7b | -| Lorem | `faker.lorem.paragraph()` | Word, words, sentences, slug (lorem-ipsum), paragraph(s), text, lines | -| Music | `faker.music.genre()` | R&B | -| Name | `faker.name.firstName()` | Cameron | -| Phone | `faker.phone.phoneNumber()` | +1 291-299-0192 | -| Random | `faker.random.locale()` | fr_CA | -| System | `faker.system.directoryPath()` | C:\Documents\Newsletters\ | -| Vehicle | `faker.vehicle.vehicle()` | 2011 Dodge Caravan | +| Module | Example | Output | +| -------- | --------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| Address | `faker.address.city()` | Lake Raoulfort | +| Animal | `faker.animal.type()` | Dog, cat, snake, bear, lion, etc. | +| Commerce | `faker.commerce.product()` | Polo t-shirt | +| Company | `faker.company.companyName()` | Zboncak and Sons | +| Database | `faker.database.engine()` | MyISAM | +| Datatype | `faker.datatype.uuid()` | 7b16dd12-935e-4acc-8381-b1e457bf0176 | +| Date | `faker.date.past()` | Sat Oct 20 2018 04:19:38 GMT-0700 (Pacific Daylight Time) | +| Finance | `faker.finance.amount()` | ¥23400 (After setting locale) | +| Git | `faker.git.commitMessage()` | feat: add products list page | +| Hacker | `faker.hacker.phrase()` | Try to reboot the SQL bus, maybe it will bypass the virtual application! | +| Helpers | `faker.helpers.arrayElement(['a', 'b', 'c'])` | `'b'` | +| Image | `faker.image.avatar()` | `https://cloudflare-ipfs.com/ipfs/Qmd3W5DuhgHirLHGVixi6V76LhCkZUz6pnFt5AJBiyvHye/avatar/233.jpg` <img src="https://cloudflare-ipfs.com/ipfs/Qmd3W5DuhgHirLHGVixi6V76LhCkZUz6pnFt5AJBiyvHye/avatar/233.jpg" width="64"/> | +| Internet | `faker.internet.color()` | #630c7b | +| Lorem | `faker.lorem.paragraph()` | Word, words, sentences, slug (lorem-ipsum), paragraph(s), text, lines | +| Music | `faker.music.genre()` | R&B | +| Name | `faker.name.firstName()` | Cameron | +| Phone | `faker.phone.phoneNumber()` | +1 291-299-0192 | +| Random | `faker.random.locale()` | fr_CA | +| System | `faker.system.directoryPath()` | C:\Documents\Newsletters\ | +| Vehicle | `faker.vehicle.vehicle()` | 2011 Dodge Caravan | ### faker.fake() |
