layout | title | description |
---|---|---|
default |
Riot FAQ |
Questions and Answers about Riot, User Interface (UI) Micro-Libary |
Riot is against the current trend of boilerplate and unneeded complexity. We think that a small, powerful API and concise syntax are extremely important things on a client-side library.
Riot is free, open source and licensed under the MIT License. There are no Additional Grant of Patent Rights.
Absolutely. It's a mature framework embraced daily.
Because it's crazy to waste developer time for a dying browser. According to W3 counter, only 1.5% are on IE8:
Statcounter says less than 1%.
This low-quality browser can safely be ignored. Riot 2.0 was launched with IE8 support but since then the use has dropped more than 50%.
W3C specification demands you use a dash in the tag name. Instead of <person>
you must write <my-person>
. Obey this rule if you care about W3C. Both work fine.
Leaving out semicolons makes the code less crowded. This is aligned with our general minimalistic approach. We use single quotes for the same reason. If you contribute to Riot, please leave out semicolons and double quotes.
The equality operator is good when you know how it works. We do this for example:
node.nodeValue = value == null ? '' : value
This causes 0
and false
to be printed but null
and undefined
are printed as an empty string. Exactly what we want!
Yes. You can use CSS normally inside a tag. The web component standard also has a mechanism of encapsulating of CSS. However, it's unlikely that this improves the overall manageability of your CSS.
Riot reduces the need for jQuery. You no longer need selectors, traversing, events and manipulation features. Some features like delegated events can be useful. jQuery plugins can be used together with Riot.
It's not evil, it just looks "old". To have JS and HTML under the same module is more important than aesthetics. The minimal Riot syntax makes event handlers look decent.
Sure. We mostly focus on stability and performance and try to provide more examples.