diff options
Diffstat (limited to 'app/assets/javascripts/static_site_editor/index.js')
-rw-r--r-- | app/assets/javascripts/static_site_editor/index.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/assets/javascripts/static_site_editor/index.js b/app/assets/javascripts/static_site_editor/index.js index 4290cb9a9ba..22f96a60df0 100644 --- a/app/assets/javascripts/static_site_editor/index.js +++ b/app/assets/javascripts/static_site_editor/index.js @@ -3,7 +3,11 @@ import StaticSiteEditor from './components/static_site_editor.vue'; import createStore from './store'; const initStaticSiteEditor = el => { - const store = createStore(); + const { projectId, path: sourcePath } = el.dataset; + + const store = createStore({ + initialState: { projectId, sourcePath }, + }); return new Vue({ el, |