{"id":13441902,"url":"https://github.com/LeetCode-OpenSource/vscode-leetcode","last_synced_at":"2025-03-20T13:31:09.631Z","repository":{"id":39341856,"uuid":"121125679","full_name":"LeetCode-OpenSource/vscode-leetcode","owner":"LeetCode-OpenSource","description":"Solve LeetCode problems in VS Code","archived":false,"fork":false,"pushed_at":"2024-09-13T07:26:20.000Z","size":11829,"stargazers_count":8213,"open_issues_count":341,"forks_count":650,"subscribers_count":85,"default_branch":"master","last_synced_at":"2024-10-29T20:08:27.366Z","etag":null,"topics":["algorithm","datastructure","interview","leetcode","vscode"],"latest_commit_sha":null,"homepage":"https://marketplace.visualstudio.com/items?itemName=shengchen.vscode-leetcode","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LeetCode-OpenSource.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-02-11T13:23:36.000Z","updated_at":"2024-10-28T16:33:49.000Z","dependencies_parsed_at":"2023-01-31T05:15:16.260Z","dependency_job_id":"26f4351c-0a8c-4e89-afe5-174118595f05","html_url":"https://github.com/LeetCode-OpenSource/vscode-leetcode","commit_stats":{"total_commits":267,"total_committers":34,"mean_commits":7.852941176470588,"dds":0.3370786516853933,"last_synced_commit":"586b3e45fe0af299775436f2e8ea2a6ed5cdb8c6"},"previous_names":["jdneo/vscode-leetcode"],"tags_count":43,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeetCode-OpenSource%2Fvscode-leetcode","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeetCode-OpenSource%2Fvscode-leetcode/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeetCode-OpenSource%2Fvscode-leetcode/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LeetCode-OpenSource%2Fvscode-leetcode/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LeetCode-OpenSource","download_url":"https://codeload.github.com/LeetCode-OpenSource/vscode-leetcode/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":234109840,"owners_count":18781541,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["algorithm","datastructure","interview","leetcode","vscode"],"created_at":"2024-07-31T03:01:39.457Z","updated_at":"2025-03-20T13:31:09.600Z","avatar_url":"https://github.com/LeetCode-OpenSource.png","language":"TypeScript","readme":"# LeetCode\n\n\u003e Solve LeetCode problems in VS Code\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/LeetCode-OpenSource/vscode-leetcode/master/resources/LeetCode.png\" alt=\"\"\u003e\n\u003c/p\u003e\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://github.com/LeetCode-OpenSource/vscode-leetcode/actions?query=workflow%3ACI+branch%3Amaster\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/workflow/status/LeetCode-OpenSource/vscode-leetcode/CI/master?style=flat-square\" alt=\"\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://gitter.im/vscode-leetcode/Lobby\"\u003e\n    \u003cimg src=\"https://img.shields.io/gitter/room/LeetCode-OpenSource/vscode-leetcode.svg?style=flat-square\" alt=\"\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://marketplace.visualstudio.com/items?itemName=LeetCode.vscode-leetcode\"\u003e\n    \u003cimg src=\"https://img.shields.io/visual-studio-marketplace/d/LeetCode.vscode-leetcode.svg?style=flat-square\" alt=\"\"\u003e\n  \u003c/a\u003e\n  \u003ca href=\"https://github.com/LeetCode-OpenSource/vscode-leetcode/blob/master/LICENSE\"\u003e\n    \u003cimg src=\"https://img.shields.io/github/license/LeetCode-OpenSource/vscode-leetcode.svg?style=flat-square\" alt=\"\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n- English Document | [中文文档](https://github.com/LeetCode-OpenSource/vscode-leetcode/blob/master/docs/README_zh-CN.md)\n\n## ❗️ Attention ❗️- Workaround to login to LeetCode endpoint\n\n\u003e Note: If you are using `leetcode.cn`, you can just ignore this section.\n\nRecently we observed that [the extension cannot login to leetcode.com endpoint anymore](https://github.com/LeetCode-OpenSource/vscode-leetcode/issues/478). The root cause of this issue is that leetcode.com changed its login mechanism and so far there is no ideal way to fix that issue.\n\nThanks for [@yihong0618](https://github.com/yihong0618) provided a workaround which can somehow mitigate this. Now you can simply click the `Sign In` button and then select `Third Party` login or `Cookie` login.\n\n\u003e Note: If you want to use third-party login(**Recommended**), please make sure your account has been connected to the third-party. If you want to use `Cookie` login, click [here](https://github.com/LeetCode-OpenSource/vscode-leetcode/issues/478#issuecomment-564757098) to see the steps.\n\n## Requirements\n\n- [VS Code 1.30.1+](https://code.visualstudio.com/)\n- [Node.js 10+](https://nodejs.org)\n  \u003e NOTE: Please make sure that `Node` is in your `PATH` environment variable. You can also use the setting `leetcode.nodePath` to specify the location of your `Node.js` executable.\n\n## Quick Start\n\n![demo](https://raw.githubusercontent.com/LeetCode-OpenSource/vscode-leetcode/master/docs/gifs/demo.gif)\n\n## Features\n\n### Sign In/Out\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/LeetCode-OpenSource/vscode-leetcode/master/docs/imgs/sign_in.png\" alt=\"Sign in\" /\u003e\n\u003c/p\u003e\n\n- Simply click `Sign in to LeetCode` in the `LeetCode Explorer` will let you **sign in** with your LeetCode account.\n\n- You can also use the following command to sign in/out:\n  - **LeetCode: Sign in**\n  - **LeetCode: Sign out**\n\n---\n\n### Switch Endpoint\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/LeetCode-OpenSource/vscode-leetcode/master/docs/imgs/endpoint.png\" alt=\"Switch Endpoint\" /\u003e\n\u003c/p\u003e\n\n- By clicking the button ![btn_endpoint](https://raw.githubusercontent.com/LeetCode-OpenSource/vscode-leetcode/master/docs/imgs/btn_endpoint.png) at the **explorer's navigation bar**, you can switch between different endpoints.\n\n- The supported endpoints are:\n\n  - **leetcode.com**\n  - **leetcode.cn**\n\n  \u003e Note: The accounts of different endpoints are **not** shared. Please make sure you are using the right endpoint. The extension will use `leetcode.com` by default.\n\n---\n\n### Pick a Problem\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/LeetCode-OpenSource/vscode-leetcode/master/docs/imgs/pick_problem.png\" alt=\"Pick a Problem\" /\u003e\n\u003c/p\u003e\n\n- Directly click on the problem or right click the problem in the `LeetCode Explorer` and select `Preview Problem` to see the problem description.\n- Select `Show Problem` to directly open the file with the problem description.\n\n  \u003e Note：You can specify the path of the workspace folder to store the problem files by updating the setting `leetcode.workspaceFolder`. The default value is：**$HOME/.leetcode/**.\n\n  \u003e You can specify whether including the problem description in comments or not by updating the setting `leetcode.showCommentDescription`.\n\n  \u003e You can switch the default language by triggering the command: `LeetCode: Switch Default Language`.\n\n---\n\n### Editor Shortcuts\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/LeetCode-OpenSource/vscode-leetcode/master/docs/imgs/shortcuts.png\" alt=\"Editor Shortcuts\" /\u003e\n\u003c/p\u003e\n\n- The extension supports 5 editor shortcuts (aka Code Lens):\n\n  - `Submit`: Submit your answer to LeetCode.\n  - `Test`: Test your answer with customized test cases.\n  - `Star/Unstar`: Star or unstar the current problem.\n  - `Solution`: Show the top voted solution for the current problem.\n  - `Description`: Show the problem description page.\n\n  \u003e Note: You can customize the shortcuts using the setting: `leetcode.editor.shortcuts`. By default, only `Submit` and `Test` shortcuts are enabled.\n\n---\n\n### Search problems by Keywords\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/LeetCode-OpenSource/vscode-leetcode/master/docs/imgs/search.png\" alt=\"Search problems by Keywords\" /\u003e\n\u003c/p\u003e\n\n- By clicking the button ![btn_search](https://raw.githubusercontent.com/LeetCode-OpenSource/vscode-leetcode/master/docs/imgs/btn_search.png) at the **explorer's navigation bar**, you can search the problems by keywords.\n\n---\n\n### Manage Session\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://raw.githubusercontent.com/LeetCode-OpenSource/vscode-leetcode/master/docs/imgs/session.png\" alt=\"Manage Session\" /\u003e\n\u003c/p\u003e\n\n- To manage your LeetCode sessions, just clicking the `LeetCode: ***` at the bottom of the status bar. You can **switch** between sessions or **create**, **delete** a session.\n\n## Settings\n\n| Setting Name                      | Description                                                                                                                                                                                                                                                   | Default Value      |\n| --------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------ |\n| `leetcode.hideSolved`             | Specify to hide the solved problems or not                                                                                                                                                                                                                    | `false`            |\n| `leetcode.defaultLanguage`        | Specify the default language used to solve the problem. Supported languages are: `bash`, `c`, `cpp`, `csharp`, `golang`, `java`, `javascript`, `kotlin`, `mysql`, `php`, `python`,`python3`,`ruby`,`rust`, `scala`, `swift`, `typescript`                     | `N/A`              |\n| `leetcode.useWsl`                 | Specify whether to use WSL or not                                                                                                                                                                                                                             | `false`            |\n| `leetcode.endpoint`               | Specify the active endpoint. Supported endpoints are: `leetcode`, `leetcode-cn`                                                                                                                                                                               | `leetcode`         |\n| `leetcode.workspaceFolder`        | Specify the path of the workspace folder to store the problem files.                                                                                                                                                                                          | `\"\"`               |\n| `leetcode.filePath`               | Specify the relative path under the workspace and the file name to save the problem files. More details can be found [here](https://github.com/LeetCode-OpenSource/vscode-leetcode/wiki/Customize-the-Relative-Folder-and-the-File-Name-of-the-Problem-File). |                    |\n| `leetcode.enableStatusBar`        | Specify whether the LeetCode status bar will be shown or not.                                                                                                                                                                                                 | `true`             |\n| `leetcode.editor.shortcuts`       | Specify the customized shortcuts in editors. Supported values are: `submit`, `test`, `star`, `solution` and `description`.                                                                                                                                    | `[\"submit, test\"]` |\n| `leetcode.enableSideMode`         | Specify whether `preview`, `solution` and `submission` tab should be grouped into the second editor column when solving a problem.                                                                                                                            | `true`             |\n| `leetcode.nodePath`               | Specify the `Node.js` executable path. for example, C:\\Program Files\\nodejs\\node.exe                                                                                                                                                                          | `node`             |\n| `leetcode.showCommentDescription` | Specify whether to include the problem description in the comments                                                                                                                                                                                            | `false`            |\n| `leetcode.useEndpointTranslation` | Use endpoint's translation (if available)                                                                                                                                                                                                                     | `true`             |\n| `leetcode.colorizeProblems`       | Add difficulty badge and colorize problems files in explorer tree                                                                                                                                                                                             | `true`             |\n| `leetcode.problems.sortStrategy`  | Specify sorting strategy for problems list                                                                                                                                                                                                                    | `None`             |\n| `leetcode.allowReportData`        | Allow LeetCode to report anonymous usage data to improve the product. list                                                                                                                                                                                    | `true`             |\n\n## Want Help?\n\nWhen you meet any problem, you can check out the [Troubleshooting](https://github.com/LeetCode-OpenSource/vscode-leetcode/wiki/Troubleshooting) and [FAQ](https://github.com/LeetCode-OpenSource/vscode-leetcode/wiki/FAQ) first.\n\nIf your problem still cannot be addressed, feel free to reach us in the [Gitter Channel](https://gitter.im/vscode-leetcode/Lobby) or [file an issue](https://github.com/LeetCode-OpenSource/vscode-leetcode/issues/new/choose).\n\n## Release Notes\n\nRefer to [CHANGELOG](https://github.com/LeetCode-OpenSource/vscode-leetcode/blob/master/CHANGELOG.md)\n\n## Acknowledgement\n\n- This extension is based on [@skygragon](https://github.com/skygragon)'s [leetcode-cli](https://github.com/skygragon/leetcode-cli) open source project.\n- Special thanks to our [contributors](https://github.com/LeetCode-OpenSource/vscode-leetcode/blob/master/ACKNOWLEDGEMENTS.md).\n","funding_links":[],"categories":["HarmonyOS","TypeScript","Containers \u0026 Language Extentions \u0026 Linting"],"sub_categories":["Windows Manager","For C++/C"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FLeetCode-OpenSource%2Fvscode-leetcode","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FLeetCode-OpenSource%2Fvscode-leetcode","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FLeetCode-OpenSource%2Fvscode-leetcode/lists"}