Changeset View
Changeset View
Standalone View
Standalone View
src/app/_pipes/marked.pipe.ts
import { Pipe, PipeTransform } from '@angular/core'; | import { Pipe, PipeTransform } from '@angular/core'; | ||||
import { Comment } from '../_models/comment'; | import { Comment } from '../_models/comment'; | ||||
import { Post } from '../_models/post'; | import { Post } from '../_models/post'; | ||||
import * as C from '../_models/constants' | import * as C from '../_models/constants'; | ||||
import * as marked from 'markdown-it'; | import * as marked from 'markdown-it'; | ||||
import markdownItRegex from 'markdown-it-regex'; | import markdownItRegex from 'markdown-it-regex'; | ||||
const md = new marked('default', { | const md = new marked('default', { | ||||
linkify: true, | linkify: true, | ||||
html: false, | html: false, | ||||
xhtmlOut: true | xhtmlOut: true | ||||
}); | }); | ||||
▲ Show 20 Lines • Show All 46 Lines • Show Last 20 Lines |