Sha256: 4a745f9a1d63b66c02dd538880273cd57c1b96f51d1ea55d50ee187b6377b3e6
Contents?: true
Size: 718 Bytes
Versions: 2
Compression:
Stored size: 718 Bytes
Contents
// Generated by Vuejs gem ~> github.com/ytbryan/vuejs // Run this example by adding <%= '<%=' %> javascript_pack_tag "<%= name %>" <%= '%' %><%= '>' %> into your // rails' view // To generate another of this component with turbolinks, please run `rails g vue something --turbolinks` import TurbolinksAdapter from 'vue-turbolinks'; import Vue from 'vue.esm' <% if options[:single] %> import App from '../parts/<%= name %>.vue' <% else %> import App from '../parts/<%= name %>/<%= name %>.vue' <% end %> Vue.use(TurbolinksAdapter) document.addEventListener('turbolinks:load', () => { if(isView("###")){ const app = new Vue({ render: h => h(App) }).$mount('#something') console.log({app}) } })
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
vuejs-1.1.0.beta3 | lib/generators/generator_templates/turbolinks/turbolinks-pack.js.erb |
vuejs-1.1.0.beta2 | lib/generators/generator_templates/turbolinks/turbolinks-pack.js.erb |