0.0.11 • Published 5 years ago
vuker v0.0.11
Vuker WIP
$ npm install vuker
or
$ yarn add vuker
What is Vuker
?
Vuker
is a prototyping tool aiming to generate everything from a model in Vue.js.
Concept (Goal)
- A code generator from a model.
- Support TypeScript
Support Generator WIP
- form
- view
- CRUD
- API
- ORM (TypeORM Wrapper)
- Seeding
Usage WIP
Initialization
$ vuker init
To make a configuration file, vuker.json
.
Code Generation
$ vuker
Command Option
option | description |
---|---|
-t , --type | Select CSS FrameWork Type. |
-f , --onlyform | only output form component |
-v , --onlyview | only output view component |
-p , --project | path to config file |
Seeding
$ vuker seed Account 5
To seed dummy data.
Example
vuker.json
{
"rootDir": "./",
"entityDir": "src/model",
"outDir": "src/components/generated",
"cssFrameWork": "BootStrap4"
}
model/Account.ts
import { Domain, Attr } from 'vuker'
@Domain()
export default class Account {
constructor() {
this.uuid = ''
this.name = ''
this.age = 0
this.email = ''
this.registeredAt = ''
}
@Attr({ show: false })
uuid: string
@Attr({ validation: 'required' })
name: string
@Attr()
age: number
@Attr({ validation: 'email' })
email: string
@Attr({ show: false })
registeredAt: string
}
TODO
- BootStrap Vue Form
- BootStrap Vue View
- Support Faker
- TypeORM Seeding Wrapper
- Semantic UI Form
- Semantic UI View
- Support custom render