ng-classy

码农软件 · 软件分类 · AngularJS 扩展 · 2019-03-16 21:57:12

软件介绍

ng-classy 可以帮助你更好的使用 AngularJS 1 和 ES6+。

安装:

npm install ng-classy

API 使用:

import classy from 'ng-classy';
/*
 * # classy.app
 * The angular module instance that your whole app shares.
 * Use it for things like angular config, constants, etc: `classy.app.config(() => {})`
 */
classy.app;
/*
 * # @classy.Service()
 * Registers 'MyService' as an injectable service on your app.
 */
@classy.Service()
class MyService {
}
/*
 * # @classy.Component(options)
 * Registers `<my-component>` as an element directive.
 * Pass in options that map to a directive definition object.
 * Has a shortcut field, `bind`, that maps to `bindToController`.
 * `options` defaults to the following in this case:
 *  {
 *    restrict: 'E',
 *    scope: {},
 *    bindToController: options.bind || {},
 *    controllerAs: 'vm',
 *    controller: MyComponent
 *  }
 */
@classy.Component({
  bind: {
   color: '='
  },
  template: 'some template with a binding to color {{vm.color}}' 
 })
class MyComponent {
}
/*
 * # @classy.State(name, options)
 * Must be called after `@classy.Component()` on a class.
 * Registers a new state with the the given name and state options.
 * The template will default to instantiating the given component with the url parameters as attributes.
 * See the example at the beginning of the README.
 */
@classy.Component({
 bind: {
   someParam: '='
   },
   template: 'we have a parameter, {{vm.someParam}}'
 }
})
@classy.State('myState', {
  url: 'url/:someParam'
})
class SomeComponent {
}

本文地址:https://www.codercto.com/soft/d/1507.html

罗辑思维

罗辑思维

罗振宇 / 长江文艺出版社 / 2013-10-25 / 36.00

本书根据罗振宇的互联网视频知识脱口秀《罗辑思维》创作。 资深媒体人罗振宇对正在到来的互联网时代有深刻的洞察。他认为,互联网正在成为我们生活中的“基础设施”,它将彻底改变人类协作的方式,使组织逐渐瓦解、消融,而个体生命的自由价值得到充分释放。 《罗辑思维》的口号是“有种、 有趣、有料”,做大家“身边的读书人”,倡导独立、理性的思考,凝聚爱智求真、积极上进、自由阳光、人格健全的年轻人。......一起来看看 《罗辑思维》 这本书的介绍吧!

RGB转16进制工具
RGB转16进制工具

RGB HEX 互转工具

XML、JSON 在线转换
XML、JSON 在线转换

在线XML、JSON转换工具

HEX HSV 转换工具
HEX HSV 转换工具

HEX HSV 互换工具