Skip to content

Commit

Permalink
docs: set repl store on mounted
Browse files Browse the repository at this point in the history
  • Loading branch information
bcakmakoglu committed Jun 13, 2022
1 parent 281b0fc commit 2bd81fe
Showing 1 changed file with 17 additions and 15 deletions.
32 changes: 17 additions & 15 deletions docs/components/Repl.vue
Original file line number Diff line number Diff line change
Expand Up @@ -53,23 +53,25 @@ for (const example of Object.keys(imports)) {
}
}
await store.setFiles(
{
...files,
'main.css': css,
},
props.mainFile ?? 'App.vue',
)
// pre-set import map
store.setImportMap({
imports: {
'@braks/vue-flow': `${location.origin}/vue-flow.es.js`,
},
onMounted(async () => {
await store.setVueVersion('3.2.25')
await store.setFiles(
{
...files,
'main.css': css,
},
props.mainFile ?? 'App.vue',
)
// pre-set import map
store.setImportMap({
imports: {
'@braks/vue-flow': `${location.origin}/vue-flow.es.js`,
},
})
})
store.setVueVersion('3.2.25')
const sfcOptions = {
script: {
reactivityTransform: true,
Expand Down

0 comments on commit 2bd81fe

Please sign in to comment.