Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ coverage
yarn.lock
package-lock.json
.doc/

dist
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

建议为目录条目添加斜杠后缀,以明确表示它是一个目录,并避免意外忽略同名文件。1

另外,此文件中的 .doc/ (第 29 行) 和 .doc (第 31 行) 是重复的。由于 docs:deploy 命令已不再使用 .doc 目录,可以考虑在另一个提交中将这两行都删除,以保持文件整洁。

dist/

Style Guide References

Footnotes

  1. 在 .gitignore 文件中,为匹配目录的模式添加末尾斜杠 (trailing slash) 是一个最佳实践。这能使模式的意图更加明确,避免错误地匹配到同名文件。

.doc
# dumi
.dumi/tmp
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
"compile": "father build && lessc assets/index.less assets/index.css",
"coverage": "rc-test --coverage",
"docs:build": "dumi build",
"docs:deploy": "gh-pages -d .doc",
"docs:deploy": "gh-pages -d dist",
"lint": "eslint src/ --ext .ts,.tsx,.jsx,.js,.md",
"now-build": "npm run docs:build",
"prepare": "dumi setup",
Expand Down