KO
|
EN
gitlite — search
Search
#javascript
#python
#hacktoberfest
#react
#ai
#typescript
#llm
#go
#golang
#android
#machine-learning
#rust
#deep-learning
#linux
vue-toggle-button
★ 11
Open GitHub ↗
Vue Toggle Button Component
Download README (.md)
Explore Similar Repositories
ram
:
Real-time Asset Monitor
The-Simplest-Faster-RCNN
:
Faster-RCNN with only one page of jupyter notebook;只用一页jupyter notebook完成Faster RCNN
vue-krpano
:
vue-krpano
covid19-corpus
:
COVID-19 corpus with annotated biomedical entities.
load-forecasting-model
:
分布式综合智慧能源系统模型——能源负荷预测模型
// repository documentation
Was this content helpful?
★ 0
(0 ratings)
Select Rating:
★
★
★
★
★
Submit Feedback
Recent Feedback
×
Download README
Do you want to download the
README.md
file for
vue-toggle-button
?
Download (.md)
# Vue Toggle Button  ## Table of contents - [Getting started](#getting-started) - [Usage](#usage) - [Available Properties](#available-properties) ## Getting started ``` npm install ``` ### Compiles and hot-reloads for development ``` npm run serve ``` ## Usage ```js <template> <div> <ToggleButton id="switch" /> </div> </template> <script> import ToggleButton from './components/ToggleButton.vue' export default { components: { ToggleButton } } </script> ``` ### Get Toggle State with Custom Event Handler ```js <template> <div> <ToggleButton id="switch" v-on:change="eventHandler" /> </div> </template> <script> import ToggleButton from './components/ToggleButton.vue' export default { components: { ToggleButton }, methods: { eventHandler(value) { console.log(value); } } } </script> ``` ### Available Properties List of available properties to use in this component: Prop | Data Type | Default | Description --------------- |------------------ |------------------ |-------------- `id` | `String` | primary | Element Id `default-state` | `Boolean` | `false` | Toggle State (true | false) `disabled` | `Boolean` | `false` | Disable the toggle button `label-enable-text` | `String` | On | Active Label `label-disable-text` | `String` | Off | In-Active Label