kero v3.2.5
Introduction
kero is a front-end model framework,As a MVVM architecture Model layer, multidimensional data Model, provide the solution for complex enterprise applications business application scenario development problems。
Features
- Abundant API
- Multidimensional Data Model
- Status identifier
- Paging cache capacity
- event trigger
Quickstart
Get kero
- npm
npm install kero- cdn
//design.yonyoucloud.com/static/kero/latest/kero.jsIntroducing kero
- ES6
import { Datatable } from "kero"- HTML
<!-- kero is dependent on knockout-->
<script src="//design.yonyoucloud.com/static/knockout/knockout-3.2.0.debug.js"></script>
<script src="//design.yonyoucloud.com/static/kero/latest/kero.js"></script>Use
definition
var myDataTable = new u.DataTable({
meta:{
field1:{required:true},
field2:{}
}
})add data
dataTable.setSimpleData([
{"id": "001","name": "tom"},
{"id": "002","name": "john"}
])setValue
var row = dataTable.createEmptyRow();
row.setValue('id','003')update
var row = dataTable.getRow(index);
row.setValue('name','jerry');delete
dataTable.removeRow(index);get all data
var json = dataTable.getSimpleData();add event trigger
dataTable1.on('valueChange',function(event){
var field = event.field,
rowId = event.rowId,
oldValue = event.oldValue,
newValue = event.newValue;
});Read the Develop documentation for information on the framework contents, templates and examples, and more.
Contributing
Develop
Developers can participate in the development of kero, but also can be based on kero two development
kero use gulp.js and webpack build the project.
clone:
$ git clone git@github.com:iuap-design/kero.gitinstall:
$ npm installbuild:
$ npm run productFeedback
If you encounter any problems , submit issues,or pull request。
Licence 版权
8 years ago
8 years ago
8 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago
9 years ago