The Markdown editor in the Mining community has been praised and many users have turned to the mining community for this reason; However, some of the problems with the editor have long been teased by friends, such as the lack of support for code highlighting and the relatively simple theme.
In order to solve this problem, rongjian, our front end boss, has come up with a more playable way for digging friends -Markdown theme customization, which can meet your personalized creative needs. The specific effects are as follows:
Theme preview: github.com/xitu/juejin…
Method of use
Add front Matter meta information to the content of the article:
---
theme: juejin
highlight: juejin
---
Copy the code
Markdown theme
Use theme to specify a theme
Built-in themes
- juejin
- github
Community Author Topics
The theme | The author |
---|---|
smartblue | The Denver nuggets GitHub |
cyanosis | The Denver nuggets GitHub |
channing-cyan | The Denver nuggets GitHub |
Code highlighting
To specify a theme using highlight, you can use all the styles in highlight.js:
- The style list
- Style preview
How can I contribute to Markdown topics
- Create a public repository using the Github default template (click the green Use This Template button)
- Will be one of the
juejin.scss
Replace with your own style, currently supports Sass, Less and CSS - Fork the repository and clone it locally, at
themes.js
File specifies the path to the style file,ref
To commit hash - in
README.md
Add your topic and author information to the community Topics section in the - Submit a pull request
So far enthusiastic digs have contributed several themes, successful contributors and successful PR partners will be able to add your theme to the list!! Come and experience it!
References:
Digs friend small handsome contribution tutorial: hand touch hand to teach you to develop nuggets article theme
Preview of his theme: