All threads / How do I have data-turbolinks-permanent inside data-behavior="vue"

Ask A Question

Notifications

You’re not receiving notifications from this thread.

How do I have data-turbolinks-permanent inside data-behavior="vue"

Alejandro Ruiz asked in Javascript

Hello,

I'm building a RoR application with Vue.js using a data-behavior="vue". I need to use the data-turbolinks-permanent to keep a nav-bar generated with bootstrap-vue.js and mdbootstrap-vue (sidenav), however it doesn't work, it is regenerated each time I click on a link.

When I test if the data-turbolinks-permanent works fine outside the div data-behavior="vue", it works perfectly, so I now I've got the the problem inside the div data-behavior="vue".

Is it possible to do that? I don't want the nav-bar and sidenav to be regenerated each time.

Thanks

Join the discussion

Want to stay up-to-date with Ruby on Rails?

Join 35,909+ developers who get early access to new tutorials, screencasts, articles, and more.

    We care about the protection of your data. Read our Privacy Policy.

    logo Created with Sketch.

    Ruby on Rails tutorials, guides, and screencasts for web developers learning Ruby, Rails, Javascript, Turbolinks, Stimulus.js, Vue.js, and more. Icons by Icons8

    © 2020 GoRails, LLC. All rights reserved.