Using editor.md in Vue (3): Using typo.css for typesetting

0. Background

Typesetting the generated typo.csselements usingeditor.mdhtml

1. Usetypo.css

1.1 Download

Download address: https://github.com/sofish/typo.css

Insert image description here

1.2 Use

Insert image description here
Unzip the project to public/static/the following

main.jsintroducecss

import '@/../public/static/typo.css-master/typo.css'

typoAdd a class to the tag that needs to be formatted

      <!--html信息-->
      <div class="typo blog-html" v-html="blog.html"></div>

2. Test

Insert image description here

x. Reference

  1. https://typo.sofi.sh/

Guess you like

Origin blog.csdn.net/ice_bear221/article/details/131183176