laroute icon indicating copy to clipboard operation
laroute copied to clipboard

[Question] Include a vue plugin?

Open Radiergummi opened this issue 7 years ago • 0 comments

This is not an issue per se, but since Laravel includes Vue by default, it would be nice to have a laroute Vue plugin available in this package. I have just written one and wanted to ask whether you are interested in including it as an additional template, defaulting to the current laroute.js implementation. You can find the gist right here: https://gist.github.com/Radiergummi/08152f9e6e1f87b57d7acc017a33fdd9

Currently, it does the following things:

  • Add a new $router property to Vue instances that has the methods route() , action(), url(), link_to() , link_to_route(), link_to_action() and match() available
  • Add a new router-link component to Vue that is available globally and works much like the one from vue-router

I'm still working on it for my current project, but if you're interested in adding it to Laroute, I'd be happy to share the source once it's finished and tested.

Radiergummi avatar Oct 16 '17 12:10 Radiergummi