mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-23 14:15:13 +00:00
fix inject for store
This commit is contained in:
parent
61232a61e6
commit
806287e62c
@ -126,6 +126,10 @@ async function createApp (ssrContext) {
|
||||
key = '$' + key
|
||||
// Add into app
|
||||
app[key] = value
|
||||
<% if (store) { %>
|
||||
// Add into store
|
||||
store[key] = app[key]
|
||||
<% } %>
|
||||
// Check if plugin not already installed
|
||||
const installKey = '__nuxt_' + key + '_installed__'
|
||||
if (Vue[installKey]) return
|
||||
@ -140,10 +144,6 @@ async function createApp (ssrContext) {
|
||||
})
|
||||
}
|
||||
})
|
||||
<% if (store) { %>
|
||||
// Add into store
|
||||
store[key] = app[key]
|
||||
<% } %>
|
||||
}
|
||||
|
||||
<% if (store) { %>
|
||||
|
Loading…
Reference in New Issue
Block a user