0.2.0 • Published 8 years ago

riot-mixin-pack v0.2.0

Weekly downloads
5
License
MIT
Repository
github
Last release
8 years ago

Build Status NPM version NPM downloads MIT License

Riot Mixin Pack

This is a series of mixins which make Riot.js more convenient.

Installation

$ npm install --save-dev riot-mixin-pack

Usage

import { domEvent } from 'riot-mixin-pack'

Or, respectively:

import domEvent from 'riot-mixin-pack/dom-event'

For ES5:

var domEvent = require('riot-mixin-pack').domEvent

Then, apply the mixin to the tag: this.mixin(domEvent)

Mixins

See more detail for each mixin:

Development

Each directory has these files:

  • index.js: source code of mixin
  • README: description about it
  • spec.js: test script
  • spec.tag: tag(s) for testing

Some note:

  • index.js should be written in ES6.
  • spec.js and spec.tag should be written in ES5.
  • In spec.tag, all tags has the prefix. For example: <sync-event-app> <sync-event-child> for syncEvent mixin.