0.1.5 • Published 6 years ago
dog-factory v0.1.5
dog-factory
dog-factory
is a simple and beauty factory library for Node.js and the browser
Installation
Node.js:
npm install dog-factory
Usage
Create instance of dogFactory
import dogFactory from 'dog-factory'
const df = new dogFactory();
Create User Model
df.create('User', {
name: 'firstName',
phone: 'phone'
})
Create Website model
df.create('Website', {
website: 'website'
})
Associating website model with users & and changing props in user model
df.changeProperty('User', {
website: df.associateFull('Website', 5)
})
Build User model array with 2 objects
df.build('User', 2)
License
Copyright (c) 2019 Ernesto Cobos c0305@cobos.xyz.
This software is licensed under the MIT License.