如何在 VS Code 中使用 TODO 文件?

发布于 2025-01-11 13:37:43 字数 237 浏览 0 评论 0原文

我在 VS Code 中创建了一个名为“todo”的文件,它显示有一个复选标记图标。我认为这可以以某种方式使用,但我没有找到任何有关它的信息。

它看起来像这样:

它看起来像什么

它如何使用?

I created a file in VS Code named "todo" and it is displayed with a checkmark icon. I thought that this could be used somehow, but I didn't find any information about it.

It looks like this:

what does it look like

How can it be used?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

念三年u 2025-01-18 13:37:43

我也想知道同样的事情!我无法找到 VSCode 处理 ToDo 文件的任何本机功能,但是我确实找到了 ToDo Tree,这是一个外观整洁的扩展,它将突出显示任何 todo/bug(等)注释,并将它们分组在一起活动栏。

查找有关 Thomas Venturini 的博客文章

I was wondering exactly the same thing! I haven't been able to find any native functionality of VSCode that deals with ToDo files, however I did find ToDo Tree, a neat looking extension which will provide highlighting for any todo/bug(etc) comments, and also group them together in the activity bar.

Find more info on Thomas Venturini's blog post

十秒萌定你 2025-01-18 13:37:43

它只是一个指示文件类型的图标。

VS Code 没有任何本机功能来对 TODO 文件执行任何特殊操作。

市场上可能有可以对该格式做一些事情的扩展。

It is just an icon indicating the file type.

VS Code doesn't have any native features for doing anything special with TODO files.

There may be extensions on the marketplace that could do something with the format.

月依秋水 2025-01-18 13:37:43

如果您在 VS Code 中创建一个名为 todoreadme 且没有任何文件格式的文件。

该文件将被识别为 markdown 文件。
(即*.md)
输入图像description here

您可以按 Ctrl+Shift+V 在 VS Code(Win 版本)中预览 TODO/README markdown 文件

,并通过以下内容创建待办事项列表:

类别或部分
( # 和其后的空格字符)

# Home
# Personal tasks

任务

[ ] Task 1
[ ] Task 2
[x] Task 3 (Completed)

文本格式

**bold**

*italic*

``highlight``

列表(在列表项之前添加制表符并在符号之后添加空格字符)

+ List item 1
- First list item.
- Second list item.
- Third list item.

+ List item 2
1. First numbered list item.
2. Second numbered list item.
3. Third numbered list item.

还支持图像或链接。

![img](https://i.sstatic.net/DxzTM.jpg?s=64)
[link text 123](https://stackoverflow.com/questions/71328373/how-to-use-todo-files-in-vs-code)

img
链接文本 123

Markdown 备忘单:
https://www.markdownguide.org/cheat-sheet/

===== =========================

基本上,我使用 category, list items, <代码>链接文本仅用于我的待办事项。

对于已完成的项目,我会在上面打勾表情符号 ✅ (Win + .)

If you create a file named todo or readme without any file format in VS Code.

The file will be recognized as a markdown file.
(i.e. *.md)
enter image description here

You can Ctrl+Shift+V to preview the a TODO/README markdown file in VS Code (Win version)

and create a todo list by the following:

Categories or Sections
( # and a space character after it )

# Home
# Personal tasks

Tasks

[ ] Task 1
[ ] Task 2
[x] Task 3 (Completed)

Text Formatting

**bold**

*italic*

``highlight``

List (Add tab before the list items and add a space character after the symbol)

+ List item 1
- First list item.
- Second list item.
- Third list item.

+ List item 2
1. First numbered list item.
2. Second numbered list item.
3. Third numbered list item.

Images or links are also supported.

![img](https://i.sstatic.net/DxzTM.jpg?s=64)
[link text 123](https://stackoverflow.com/questions/71328373/how-to-use-todo-files-in-vs-code)

img
link text 123

markdown cheat sheet:
https://www.markdownguide.org/cheat-sheet/

==============================

Basically, I am using category, list items, link text for my todo only.

For completed items, I would put a tick emoji ✅ (Win + .)

自此以后,行同陌路 2025-01-18 13:37:43

实际上有一种方法可以通过使用 Todo+ 扩展

创建一个带有连字符和空格的待办事项:

- Sample Todo Item

通过用 + 替换连字符来将待办事项标记为完整,它应该变成绿色。

+ Completed Todo Item

不遵循这些格式的文本将标记为评论

Sample comment

在底部栏中,将有一个百分比指示器,指示您已完成/剩余的任务数量。
这是百分比指示器文件示例

您可以右键单击特定的待办事项将其标记为已取消、已开始和已完成。这将为待办事项使用特殊符号并添加时间戳。我发现这对于单独工作来说有点混乱,但在团队情况下可能很有用。

(编辑:我以为它是内置的,添加了扩展链接)

There is actually a way to add some functionality with the todo files by using the Todo+ extension.

Create a todo item with a hyphen and a space:

- Sample Todo Item

Mark todo items as complete by replacing the hyphen with a +, it should turn green.

+ Completed Todo Item

Text not following these formats will mark as a comment

Sample comment

At the bottom bar, there will be a percentage indicator of the number of tasks you have completed/have left.
Here is a picture of the percentage indicator and a file example.

You can right click on specific todo items to mark as cancelled and started, and done. This will use special symbols for the todo items as well as adding timestamps. I've found this to be a bit clutter for solo work, but could be useful in a team situation.

(edit: I thought it was built in, added extension link)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文