Skip to content

Instantly share code, notes, and snippets.

<button class="btn btn-{{ size }}"></button>
"aliasify": {
"aliases": {
"vue": "vue/dist/vue.js"
}
function mountComponent(component, element, props = {}) {
new Vue({
render(createElement) {
return createElement(component, { props });
}
}).$mount(element);
}
import Vue from 'vue'
import App from './App.vue'
new Vue({
el: '#app',
store,
render: h => h(App)
});
<div id="app"></div>
@sunnyone
sunnyone / sample.html
Created November 1, 2016 08:31
Vue template
<div>
<a v-bind:href="bind1" v-on:click="click1">{{ text }}</a>
</div>
@sunnyone
sunnyone / template2.js
Created November 1, 2016 08:31
vueify compiled for Vue 2.x
__vue__options__.render = function(){with(this){return _h('div',[_h('a',{attrs:{"href":bind1},on:{"click":click1}},[_s(text)])])}}
@sunnyone
sunnyone / template1.js
Created November 1, 2016 08:30
vueify compiled for Vue 1.x
(typeof module.exports === "function"? module.exports.options: module.exports).template = "\n<div>\n <a v-bind:href=\"bind1\" v-on:click=\"click1\">{{ text }}</a>\n</div>\n"
function Test-ExeIsAdobe {
param([string]$Filename)
if ($Filename -inotmatch ".exe$") {
return $false
}
try {
$sign = [System.Security.Cryptography.X509Certificates.X509Certificate2]::CreateFromSignedFile($filename)
$sign.Subject -match "Adobe Systems"
@sunnyone
sunnyone / KotlinSample.kt
Created August 8, 2016 02:30
Kotlin <-> Java interop checked exception example
class KotlinSample {
fun hello() {
throw Exception("checked exception?")
}
}