All Projects → gluons → vue-github-buttons

gluons / vue-github-buttons

Licence: Apache-2.0 license
GitHub buttons component for Vue.

Programming Languages

typescript
32286 projects
Vue
7211 projects
javascript
184084 projects - #8 most used programming language
SCSS
7915 projects
HTML
75241 projects

Projects that are alternatives of or similar to vue-github-buttons

shadow
Shadow dom support for Vue
Stars: ✭ 46 (+27.78%)
Mutual labels:  vue-component
vue-drag-zone
Drag Zone component for @vuejs
Stars: ✭ 127 (+252.78%)
Mutual labels:  vue-component
vue-telegram-login
Vue component for Telegram login
Stars: ✭ 73 (+102.78%)
Mutual labels:  vue-component
vue-snowf
Snowfall component for Vue.js, let it snow on your page! ❄ demo: https://fuxy526.github.io/snowf/
Stars: ✭ 38 (+5.56%)
Mutual labels:  vue-component
vue-input-contenteditable
The same features you expect from `<input type="text">` but in a `contenteditable` Vue component
Stars: ✭ 19 (-47.22%)
Mutual labels:  vue-component
vue-odometer
Vue.js(v2.x+) component wrap for Odometer.js
Stars: ✭ 63 (+75%)
Mutual labels:  vue-component
vue-img-orientation-changer
A vue plugin that can help you display image in correct orientation.
Stars: ✭ 38 (+5.56%)
Mutual labels:  vue-component
vue-tiny-pagination
A Vue component for create a tiny pagination with Flexbox
Stars: ✭ 20 (-44.44%)
Mutual labels:  vue-component
v-owl-carousel
🦉 VueJS wrapper for Owl Carousel
Stars: ✭ 46 (+27.78%)
Mutual labels:  vue-component
vue-ele-import
超简单、好用的 element-ui Excel 导入组件
Stars: ✭ 50 (+38.89%)
Mutual labels:  vue-component
vstx-data-table
A data table component for the Vue Stacks Ecosystem
Stars: ✭ 34 (-5.56%)
Mutual labels:  vue-component
vue-eva-input
A beautiful input component based on Eva Design System and Vue.
Stars: ✭ 17 (-52.78%)
Mutual labels:  vue-component
vue-loading
Loading bar for Vue.js apps using axios
Stars: ✭ 19 (-47.22%)
Mutual labels:  vue-component
ui-nuclear-mobile
A configurable Mobile UI based on Antd Mobile and Vue
Stars: ✭ 61 (+69.44%)
Mutual labels:  vue-component
layui-vue
layui - vue(谐音:类 UI) 是 一 套 Vue 3.0 的 桌 面 端 组 件 库
Stars: ✭ 112 (+211.11%)
Mutual labels:  vue-component
unique-ui
一个用于Vue2.x的移动端组件库
Stars: ✭ 43 (+19.44%)
Mutual labels:  vue-component
vue-pattern-input
Use RegExp to limit input
Stars: ✭ 25 (-30.56%)
Mutual labels:  vue-component
vue-dictaphone
🎙️ Vue.js dictaphone component to record audio from the user
Stars: ✭ 22 (-38.89%)
Mutual labels:  vue-component
vue-github-activity
A Vue based github feed activity component.
Stars: ✭ 28 (-22.22%)
Mutual labels:  vue-component
vue-circle-choice
A circle color choice and navigation with Vue.js
Stars: ✭ 20 (-44.44%)
Mutual labels:  vue-component

Vue GitHub Buttons

license vue 2 npm npm Travis Codacy grade ESLint Gluons

:octocat: GitHub buttons component for Vue.

Installation

Via NPM:

NPM

npm install vue-github-buttons

Via Yarn:

yarn add vue-github-buttons

Demo

Go to https://gluons.github.io/vue-github-buttons

Usage

import Vue from 'vue';
import VueGitHubButtons from 'vue-github-buttons';
import App from './App.vue';

// Stylesheet
import 'vue-github-buttons/dist/vue-github-buttons.css';

Vue.use(VueGitHubButtons);
// Or if your don't want to use cache
Vue.use(VueGitHubButtons, { useCache: false });

new Vue({
	el: '#app',
	render: h => h(App)
});
<template>
	<div id="app">
		<gh-btns-watch slug="vuejs/vue" show-count></gh-btns-watch>
		<gh-btns-star slug="vuejs/vue" show-count></gh-btns-star>
		<gh-btns-fork slug="vuejs/vue" show-count></gh-btns-fork>
		<gh-btns-follow user="yyx990803" show-count></gh-btns-follow>
	</div>
</template>

<script>
// JavaScript ...
</script>

<style>
/* Style ... */
</style>

Using with Nuxt

Add vue-github-buttons/nuxt to modules in nuxt.config.js.

module.exports = {
	modules: [
		'vue-github-buttons/nuxt',
		// Or with options
		['vue-github-buttons/nuxt', {
			css: false, // Don't include CSS
			useCache: false // Don't use cache
		}]
	]
};

Module options

css

Type: Boolean
Default: true

Include Vue GitHub Buttons's CSS.

useCache

Type: Boolean
Default: true

Enable caching. (See below)

Using with VuePress

Require VuePress v1.x

Add Vue GitHub Buttons to your plugins in .vuepress/config.js.

module.exports = {
	plugins: [
		require('vue-github-buttons/plugins/vuepress'),

		/* Or using plugin with options */

		[
			require('vue-github-buttons/plugins/vuepress'),
			{
				useCache: false
			}
		]
	]
}

Plugin options are the same as Vue plugin options.

API

Plugin Options

useCache

Type: Boolean
Default: true

Enable count number caching. (Use session storage)

GitHub API has limited requests. So, caching may be useful when user refresh the webpage.

Vue.use(VueGitHubButtons, { useCache: false }); // Disable cache

Components

gh-btns-watch

👁️ A watch button.

  • slug - GitHub slug (username/repo).
  • show-count - Enable displaying the count number.

gh-btns-star

A star button.

  • slug - GitHub slug (username/repo).
  • show-count - Enable displaying the count number.

gh-btns-fork

🍴 A fork button.

  • slug - GitHub slug (username/repo).
  • show-count - Enable displaying the count number.

gh-btns-follow

👤 A follow button.

  • user - GitHub username.
  • show-count - Enable displaying the count number.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].