内容简介:Riot 4.6.0 发布了,更新内容如下: 修复了在<template>标签中呈现文本表达式的情况下的小写问题 更新改进了核心代码、编译器和 dom 绑定 通过<slot>属性添加对 HOC(高阶组件)组件的支持,例如: Provider <...
Riot 4.6.0 发布了,更新内容如下:
- 修复了在<template>标签中呈现文本表达式的情况下的小写问题
- 更新改进了核心代码、编译器和 dom 绑定
- 通过<slot>属性添加对 HOC(高阶组件)组件的支持,例如:
Provider
<hoc-component>
<slot message={ message } theme={ theme }/>
<script>
export default {
message: 'hello',
theme: 'dark'
}
</script>
</hoc-component>
Consumer
<app>
<hoc-component>
<!-- the {message} property will be provided by the <hoc-component> -->
<h1>{ message }</h1>
<!-- the {theme} property will be provided by the <hoc-component> -->
<sidebar theme={ theme }/>
</hoc-component>
<!-- the {message} property is not available outside of the <hoc-component> -->
<p>{ message }</p>
</app>
Riot 是一个简单而优雅的基于组件的 UI 库,为所有现代浏览器带来了自定义组件。其支持浏览器包括:
它的体积也很小,只有 6k:
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网
猜你喜欢:- One 框架 2.0.13 发布
- Total.js 框架 v2.6.0 发布,Node.js 的 MVC 框架
- Total.js 框架 v2.6.0 发布,Node.js 的 MVC 框架
- 快嘉框架 v1.6 更新发布,J2EE 开发框架实例
- 快嘉框架 v2.0 更新发布,J2EE 开发框架实例
- 快嘉框架 v2.0 更新发布,J2EE 开发框架实例
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
How to Build a Billion Dollar App
George Berkowski / Little, Brown Book Group / 2015-4-1 / USD 24.95
Apps have changed the way we communicate, shop, play, interact and travel and their phenomenal popularity has presented possibly the biggest business opportunity in history. In How to Build a Billi......一起来看看 《How to Build a Billion Dollar App》 这本书的介绍吧!