@ElevateBart
Discord, Twitter, Github
VueJs Chicago Meetup
Storybook
Vue-Styleguidist
Alligator
Oh! I don't have time for this either!
vue add storybook
import MyButton from "./MyButton.vue";
import { action } from "@storybook/addon-actions";
export default {
component: MyButton,
title: "Button"
};
export const withJSX = () =>
<MyButton onClick={action("clicked")}>Click Me</MyButton>
vue add styleguidist
<template>
<button :style="`background-color:${color}`" > <!-- @slot text of the button --> <slot />
</button>
</template>
<script>
export default {
props: { /**
* Set the background color of the button
* @values blue, red, green
*/ color: {
type: String,
default: "blue"
}
}
}
</script>
position: fixed
@ElevateBart
Discord, Twitter, Github