Skip to content

Commit 479e3ff

Browse files
authored
feat(vue-app): inject into plugins context (nuxt#7212)
1 parent a2495a6 commit 479e3ff

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

packages/vue-app/template/index.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -174,6 +174,10 @@ async function createApp (ssrContext) {
174174
key = '$' + key
175175
// Add into app
176176
app[key] = value
177+
// Add into context
178+
if (!app.context[key]) {
179+
app.context[key] = value
180+
}
177181
<% if (store) { %>
178182
// Add into store
179183
store[key] = app[key]

0 commit comments

Comments
 (0)