@elgervb/mock-data
TypeScript icon, indicating that this package has built-in type declarations

1.0.3 • Public • Published

Build Status dependencies Status devDependencies Status Maintainability Test Coverage

MOCK-DATA

Mock data made easy, while maintaining type-safety and reducing boilerplate code.

Examples

Simple random models:

examples/random.ts
npx ts-node ./src/examples/random.ts Output:

{
  active: false,
  created: 1986-11-29T23:00:00.000Z,
  id: '99c06715-f119-45f6-8544-01ca94bed5ff',
  name: 'VZxYf1x5w4'
}

Register blueprints:

examples/blueprints.ts
npx ts-node ./src/examples/blueprints.ts Output:

[
  {
    brand: 'XCSLNHDjQS',
    color: 'J7VfZvbLpO',
    guid: 'c4027a22-faf3-4168-9bc4-a1bb11c78fdc',
    type: 'rQI3EoILRW',
    wheels: [ [Object], [Object], [Object], [Object] ]
  },
  {
    brand: '6cbBqZZD3J',
    color: 'UJu4RwwYkt',
    guid: 'b5b6b810-7dd2-4afe-8765-95ab6ce5529d',
    type: 'LBIdfIFmZ9',
    wheels: [ [Object], [Object], [Object], [Object] ]
  },
  ...

Package Sidebar

Install

npm i @elgervb/mock-data

Weekly Downloads

0

Version

1.0.3

License

ISC

Unpacked Size

265 kB

Total Files

154

Last publish

Collaborators

  • elgervb