https://gitter.im/riot/riot" data-canonical-src="https://img.shields.io/badge/GITTER-JOIN_CHAT_%E2%86%92-1dce73.svg?style=flat-square" style="box-sizing: content-box; max-width: 100%;">
| Framework | Version | Minified Size (gzip) |
|---|---|---|
| Angular2 | 2 | too much |
| Ember | 2.9.1 | 110.30kb |
| Angular | 1.5.8 | 56.28kb |
| Polymer + Web Components Polyfill Lite | 1.7.0 | 50.25kb |
| React | 15.4.0 | 45.05kb |
| Web Components Polyfill | 0.7.22 | 33.66kb |
| Vue | 1.0.28 | 26.83kb |
| Vue | 2.1.0 | 25.44kb |
| Riot | 3.0.1 | 9.75kb |
Riot is supported by all modern browsers and it does not require any additional polyfill
Riot brings custom tags to all modern browsers. Think React + Polymer but with enjoyable syntax and a small learning curve.
<timer>
<p>Seconds Elapsed: { time }</p>
this.time = opts.start || 0
tick() {
this.update({ time: ++this.time })
}
var timer = setInterval(this.tick, 1000)
this.on('unmount', function() {
clearInterval(timer)
})
</timer>riot.mount('timer', { start: 0 })Custom tags lets you build complex views with HTML.
<timetable>
<timer start="0"></timer>
<timer start="10"></timer>
<timer start="20"></timer>
</timetable>HTML syntax is the de facto language on the web and it's designed for building user interfaces. The syntax is explicit, nesting is inherent to the language and attributes offer a clean way to provide options for custom tags.
data- attributes.class={ enabled: is_enabled, hidden: hasErrors() }.render, state, or constructor.Add #{ items.length + 1 } or class="item { selected: flag }"If you are reading this it's already a good sign and we are thankful for it! We try our best working as much as we could on riot but your help is always appreciated.
If you want to contribute to riot helping us maintaining the project please check first the list of our open issues to understand whether there is a task where you could help.
Riot is mainly developed on UNIX systems so you will be able to run all the commands necessary to build and test the library using our Makefile. If you are on a Microsoft machine it could be harder to set up you development environment properly.
Following the steps below you should be able to properly submit your patch to the project
$ git clone git@github.com:riot/riot.git && cd riot$ git checkout -b feature/my-awesome-patch$ npm i# To build and test riot
$ make riot
# To build without testing
$ make raw
# To build anytime you change a src file
$ make watch
# To bench riot ( it requires ctrl+c to exit )
$ make perfdev branch making sure you have read our pull request templateRiot is made with ![]()
It's actively maintained by:
| 欢迎光临 守望者--AIR技术交流 (http://www.airmyth.com/) |