react-case:React的内联声明式逻辑

时间:2021-05-07 13:20:59
【文件属性】:
文件名称:react-case:React的内联声明式逻辑
文件大小:5KB
文件格式:ZIP
更新时间:2021-05-07 13:20:59
react retired JavaScript React案例 厌倦了三元运算符,而if-else在您的render方法之上? 是否需要没有奇怪语法的声明性逻辑? Me too. Sorry to hear that. 安装 npm install react-conditional --save 用法 var React = require("react"); var conditionals = require("react-case"); var Condition = conditionals.Condition; var Case = conditionals.Case; var mp = document.querySelector("#mount"
【文件预览】:
react-case-master
----example.html(210B)
----webpack.config.js(329B)
----lib()
--------Condition.jsx(1KB)
----test.js(1KB)
----README.md(2KB)
----.gitignore(28B)
----index.js(4KB)
----package.json(643B)

网友评论