Commit 8ce85c49 authored by Kev's avatar Kev

Replace v-html with v-safe-html in simple_viewer.vue

parent 4e0d6868
<script>
/* eslint-disable vue/no-v-html */
import { GlIcon } from '@gitlab/ui';
import { GlIcon, GlSafeHtmlDirective as SafeHtml } from '@gitlab/ui';
import ViewerMixin from './mixins';
import { HIGHLIGHT_CLASS_NAME } from './constants';
......@@ -8,6 +7,9 @@ export default {
components: {
GlIcon,
},
directives: {
SafeHtml,
},
mixins: [ViewerMixin],
data() {
return {
......@@ -64,7 +66,7 @@ export default {
</a>
</div>
<div class="blob-content">
<pre class="code highlight"><code id="blob-code-content" v-html="content"></code></pre>
<pre class="code highlight"><code id="blob-code-content" v-safe-html="content"></code></pre>
</div>
</div>
</template>
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment