Skip to content

Instantly share code, notes, and snippets.

Avatar
👨‍💻
Debugging

Thien Nguyen tatthien

👨‍💻
Debugging
View GitHub Profile
@tatthien
tatthien / Notification.vue
Created Mar 5, 2018
Vue Notie - snippet #6
View Notification.vue
<script>
export default {
methods: {
success (message) {
this.$_vuenotie_success(message)
}
}
}
</script>
@tatthien
tatthien / Notification.vue
Last active Mar 5, 2018
Vue Notie - snippet #5
View Notification.vue
<template>
<div class="notifications">
<button @click="$_vuenotie_success('Success!')">Success</button>
<button @click="$_vuenotie_warning('Warning!')">Warning</button>
<button @click="$_vuenotie_error('Error!')">Error</button>
<button @click="$_vuenotie_infor('Information!')">Information</button>
</div>
</template>
@tatthien
tatthien / vue-notie.js
Created Mar 5, 2018
Vue Notie - snippet #4
View vue-notie.js
import { alert } from 'notie'
export default {
install (Vue, options) {
Vue.mixin({
methods: {
$_vuenotie_success (message) {
alert({
type: 1,
text: message
@tatthien
tatthien / vue-notie.js
Created Mar 5, 2018
Vue Notie - snippet #3
View vue-notie.js
import { alert } from 'notie'
export default {
install (Vue, options) {
Vue.mixin({
methods: {
$_vuenotie_success (message) {
alert({
type: 1,
text: message
@tatthien
tatthien / main.js
Created Mar 5, 2018
Vue Notie - snippet #2
View main.js
import Vue from 'vue'
import VueNotie from './plugins/vue-notie'
Vue.use(VueNotie)
@tatthien
tatthien / vue-notie.js
Last active Mar 5, 2018
Vue Notie - snippet #1
View vue-notie.js
export default {
install (Vue, options) {
Vue.mixin({
// global assets go here
})
}
}
View index.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<script id="jsbin-javascript">
View index.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<script id="jsbin-javascript">
View commit-emoji.md
  • 🎨 when improving the format/structure of the code
  • 🚀 when improving performance
  • ✏️ when writing docs
  • 💡 new idea
  • 🚧 work in progress
  • when adding feature
  • when removing feature
  • 🔈 when adding logging
  • 🔇 when reducing logging
  • 🐛 when fixing a bug
@tatthien
tatthien / bible-button.php
Created Apr 12, 2017
Custom Bible Button
View bible-button.php
<?php
/*
Plugin Name: Custom Bible Button
Plugin URI: https://tatthien.com
Description: Add custom media button
Version: 1.0.0
Author: Tat Thien
Author URI: https://tatthien.com
License: A "Slug" license name e.g. GPL2
Text Domain: text_domain
You can’t perform that action at this time.