当前位置:首页 > IT科技类资讯

有人在Github上用几行代码就造了个锤子便签

 锤子便签,有人作为老罗的上用又一款设计感爆棚的产品,可能是行代史上最漂亮的便签应用,你或许会因它重新喜欢上记录和表达。码造它不仅可以输入文字,个锤还支持插入图片。便签你还可以随时随地将便签内容生成精美的有人长微博或网页并分享。

近日,上用猿妹在GitHub上看到有人用几行代码就做出了一个基于锤子便签的源码库行代markdown主题。这样一来,码造无论在哪里都能使用锤子便签的个锤样式,猿妹只能说这位创建者真是便签爱惨了锤子便签。

这个项目虽然只有11个Star,有人但却有1700个分支。上用

你可以通过这个网址在线体验一下,行代或者预览一下它的界面,和锤子便签进行一个对比,看看是高防服务器不是一样美观。(地址:https://nihaojob.github.io/markdown-css-smartisan/examples/index.html)

markdown-css-smartisan安装

从CDNJS手动下载,或者使用npm或yarn下载:

# use npm $ npm install markdown-css-smartisan # use yarn $ yarn add markdown-css-smartisan 

用法

导入github-markdown.css文件,然后将markdown-body类添加到渲染的Markdown的容器中,并为其设置宽度。

import markdown-css-smartisan 

如果要突出显示代码语法,请使用从GitHub /markdownAPI呈现的GitHub Flavored Markdown 。

<meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" type="text/css" href="https://cdn.jsdelivr.net/npm/markdown-css-smartisan/github-markdown.css" /> <style> .markdown-body {  width: 80%; margin: 0 auto; } </style> <article class="markdown-body"> <h1>Unicorns</h1> <p>All the things</p> </article> 

最后附上GitHub地址:https://github.com/nihaojob/markdown-css-smartisan

分享到:

滇ICP备2023006006号-16