Skip to content
Snippets Groups Projects

Refactor-v-html-markdown.vue

Merged Abhijeet Chatterjee requested to merge (removed):Remove-v-html-from-markdown.vue into master
All threads resolved!
<script>
import katex from 'katex';
import marked from 'marked';
import { GlSafeHtmlDirective as SafeHtml } from '@gitlab/ui';
import { sanitize } from '~/lib/dompurify';
import { hasContent, markdownConfig } from '~/lib/utils/text_utility';
import Prompt from './prompt.vue';
@@ -138,6 +139,9 @@ export default {
components: {
prompt: Prompt,
},
directives: {
SafeHtml,
},
inject: ['relativeRawPath'],
props: {
cell: {
@@ -159,7 +163,7 @@ export default {
<template>
<div class="cell text-cell">
<prompt />
<div class="markdown" v-html="markdown /* eslint-disable-line vue/no-v-html */"></div>
+1
<div v-safe-html="markdown" class="markdown"></div>
</div>
</template>
Loading