Answer the question
In order to leave comments, you need to log in
How to reload Vue after loading code?
There is a code that pulls svg from the site
In SVG, @click is assigned to some objects.
If I insert the svg into the template right away, everything works, but if I load the svg after the page loads, then the click will not work.
How to fix?
<div class="col-md-12 svg-container" v-html="svg">
</div>
axios.get( 'site/svg').then(response => {
this.svg = response.data
})
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question