npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

turpan-remove-space

v0.1.1

Published

remove the space between English word and Chinese characters in markdown files

Downloads

5

Readme

编写文档时,我们提倡英文单词与中文字符之间,有一个空格(参考《中文技术文档写作规范》)。

有空格的写法:学习 JavaScript 语言

无空格的写法:学习JavaScript语言

印刷排版时,往往要求英文单词与中文字符之间,不能有空格。Turpan-remove-space 就是移除这种空格的工具,返回处理后的 HTML 文件。

用法

# 安装
$ npm install -g turpan-remove-space

接着,将所有 Markdown 文件放在一个目录之中。(注意:暂时不支持子目录之中的 Markdown 文件。)

$ trs --dir /path/to/markdown/dir

运行上面的命令之后,会在该目录旁,生成另一个目录,比如docs-1499348264449,里面包含了转码后的 HTML 文件。

转码规则

单个英文词汇与汉字之间的空格,都将被去除。

转码前:学习 JavaScript 语言

转码后:学习JavaScript语言

此外,还可以自己指定去除空格的词汇。

$ tse --dir /path/to/markdown/dir --word '计算机,人工智慧'

上面代码中,多个词汇之间使用半角逗号分隔。注意,逗号前后不能有空格。

转码前:学习 计算机 语言

转码后:学习计算机语言