Sign Up for Free

RunKit +

Try any Node.js package right in your browser

This is a playground to test code. It runs a full Node.js environment and already has all of npm’s 400,000 packages pre-installed, including uxcore-switch with all npm packages installed. Try it out:

var uxcoreSwitch = require("uxcore-switch")

This service is provided by RunKit and is not affiliated with npm, Inc or the package authors.

uxcore-switch v0.1.14

uxcore-switch component for uxcore.


uxcore-switch Dependency Status devDependency Status

TL;DR

uxcore-switch ui component for react

setup develop environment

$ git clone https://github.com/uxcore/uxcore-switch
$ cd uxcore-switch
$ npm install
$ gulp server

Usage

demo

http://uxcore.github.io/

API

Props

配置项类型必填默认值功能/备注
prefixClsstringoptional'kuma-switch'类名前缀
classNamestringoptional-额外类名
checkedbooleanoptionalfalse是否被选中
defaultCheckedbooleanoptionalfalse非受限模式
onChangeFunction(checked)required变化时发生
checkedChildrenstringoptional-选中时的文案
unCheckedChildrenstringoptional-未选中时的文案
loadingbooloptionalfalseloading 状态

Metadata

RunKit is a free, in-browser JavaScript dev environment for prototyping Node.js code, with every npm package installed. Sign up to share your code.
Sign Up for Free