Skip to content

Navigation Menu

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings
This repository was archived by the owner on Jan 1, 2020. It is now read-only.

rfberaldo/vue-checkbox-switch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Vue Checkbox Switch

A simple Vue component for checkbox's switch style based on vue-bulma/switch and this PR on Bulma

Installation

You don't need any dependencies except Vuejs 2

Copy src/Switch.vue to your components folder

Example

Screenshot

<template>
    <app-switch classes="is-warning" v-model="value" checked>Test</app-switch>
</template>

<script>
    import Switch from './components/Switch'

    export default {
        components: {
            'app-switch': Switch
        },
        data() {
            return {
                value: false,
                text: ''
            }
        },
        watch: {
            value(val) {
                this.text = val ? 'Yes' : 'No'
            }
        }
    }
</script>

Twitter @rafaelpimpa

Releases

No releases published

Packages

No packages published

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.