nanocomponent-adapters/angularjs
small wrapper around nanocomponents for angular 1.x
usage
wrappedComponent = toAngularjs(Component, name, attrs, angular)
registers a new module with the given Angular instance and returns a string of the module's name.
- Component: A nanocomponent constructor
- name: camelCase name for the component
- attrs: a list of the arguments passed to
Component#render
- angular: angular instance
example
var angular = var toAngularjs = var Nanocomponent = var html = { super thiscolor = null } { console } { thiscolor = color return html` Click Me ` } { return color !== thiscolor } var customButton = angular
in your template: