mirror of
https://github.com/nuxt/nuxt.git
synced 2025-01-30 15:22:39 +00:00
Use ES6 syntax for hooks in transition key
This commit is contained in:
parent
d9fe4b9612
commit
a99161f685
@ -41,7 +41,12 @@ require('<%= pluginPath %>')
|
||||
// root instance
|
||||
// here we inject the router and store to all child components,
|
||||
// making them available everywhere as `this.$router` and `this.$store`.
|
||||
const defaultTransition = <%= serialize(transition) %>
|
||||
const defaultTransition = <%=
|
||||
serialize(transition)
|
||||
.replace('beforeEnter(', 'function(').replace('enter(', 'function(').replace('afterEnter(', 'function(')
|
||||
.replace('enterCancelled(', 'function(').replace('beforeLeave(', 'function(').replace('leave(', 'function(')
|
||||
.replace('afterLeave(', 'function(').replace('leaveCancelled(', 'function(')
|
||||
%>
|
||||
const app = {
|
||||
router,
|
||||
<%= (store ? 'store,' : '') %>
|
||||
|
Loading…
Reference in New Issue
Block a user