Open GuoYongfeng opened 8 years ago
目前整体划分了八大板块内容:
iuap-design.github.io
gitbook-plugin-iuap-design
generate-uui
iuap-design
datetimepicker
datatable
tree
grid
scaffold
webpack-dev-boilerplate
react-starter-kit
cloud-starter-kit
user-group
我们的官网展示很简单,但是资源较多
node server/app.js
目前大家都可以往github上的iUAP Design上面自由推送代码,但是服务器上部署的代码真正的生效,目前只有我有权限,而且需要我按固定的格式提交代码才会生效。这是因为我们使用的webhook做的钩子,实现的自动化部署,
不要再去写面条一样的jquery代码 合理的组织js代码 纯函数式
不要再去写面条一样的jquery代码
/** * [task description] * @param {[type]} [description] */ function Init(){ domRneder(); handleEvent(); } /** * [task description] * @param {[type]} [description] */ function domRneder(){ console.log('domRneder.....') } /** * [task description] * @param {[type]} [description] */ function handleEvent(){ console.log('handleEvent......') }
var Index = { /** * [task description] * @param {[type]} [description] */ init: function (){ this.domRender(); this.handleEvent(); }, /** * [task description] * @param {[type]} [description] */ domRneder: function(){ console.log('domRender'); }, /** * [task description] * @param {[type]} [description] */ handleEvent: function(){ console.log('handleEvent'); this.otherFn(); }, /** * [task description] * @param {[type]} [description] */ otherFn: function(){ console.log('todo....') } }; Index.init();
/** * [task description] * @param {[type]} [description] */ var Robot = function(){ this.a = 'a'; this.b = 'b'; this.init(); } /** * [task description] * @param {[type]} [description] */ Robot.prototype.init = function(){ this.say(); this.work(); } /** * [task description] * @param {[type]} [description] */ Robot.prototype.say = function(){ console.log('say...') } /** * [task description] * @param {[type]} [description] */ Robot.prototype.work = function(){ console.log('work...') } new Robot();
/** * [task description] * @param {[type]} [description] */ function Detail(){ this.init(); }; /** * [task description] * @param {[type]} [description] */ Detail.view = { "PRICE_BTN" : $("._price_btn a") } /** * [task description] * @param {[type]} [description] */ Detail.prototype = { init : function(){ this.initUrl(); }, initUrl : function(){ console.log('handle.....') } } new Detail();
class Person { constructor(){ this.a = 'a'; this.b = 'b' } say(){ console.log('say.....') } } new Person();
// 1 if ( a > 0 ) { } // 2 var x = 20; // 3 for ( var i = 0, len = arr.length; i < len; i++ ) { }
/** * [task description] * @param {[type]} [description] */ function Detail(){ this.init(); // 变量定义 var a = 'xx'; };
// bad function a ( ) { if () { } for () {} if () { } } // good function a ( ) { if () { } for () {} if () { } }
// bad var x1 = 0, a_77 = b; // good var newFeature = [];
// bad $.a().b({a: b}).c().dd() // good $.a() .b({a: b}) .c()
// bad var a = {a: 9,c:0,cccc:'9409043'} // good var a = { a: 9, c: 0, cccc: '9409043' }
git status
欢迎大家盖楼,提出建议和意见。
2016/6/21 团队工作会议
1.部门工作整体介绍
目前整体划分了八大板块内容:
2.我们的代码仓库的介绍
官网
iuap-design.github.io
官网的代码gitbook-plugin-iuap-design
把我们的md文档转换成html的gitbook插件generate-uui
完成两件事情,将资源放在dist目录实现CDN分发、聚合其他各个相关仓库代码框架
iuap-design
基于设计语言iUAP Design的UI框架datetimepicker
日期时间相关的datatable
马上需要改名为kero,kero是一个基于ko的扩展的类库,做为MVVM架构中Model层的增强,主要用于处理企业级复杂数据交互。tree
处理复杂树形数据展现的tree插件grid
生态
scaffold
标准化目录结构 -webpack-dev-boilerplate
基于webpack + react的脚手架react-starter-kit
暂无内容cloud-starter-kit
基于koa+gulp+require的项目脚手架user-group
用户维护仓库团队
3.官网和CDN构建的过程
CDN
官网构建
我们的官网展示很简单,但是资源较多
node server/app.js
即可,另外,我把所以和server相关的东西都放在server目录下权限
目前大家都可以往github上的iUAP Design上面自由推送代码,但是服务器上部署的代码真正的生效,目前只有我有权限,而且需要我按固定的格式提交代码才会生效。这是因为我们使用的webhook做的钩子,实现的自动化部署,
4.代码规范
单例模式
构造函数加原型
ES6 Module
代码间隙
注释
公共的方法进行抽离
4个空格缩进
命名
断行
json格式
5.git的使用和提交信息规范
git status
,时刻知道你当前在什么分支,当前的文件处于什么样的状态