# leetcode.nvim
đĨ Solve [LeetCode] problems within [Neovim] đĨ
đēđ¸ English, đ¨đŗ
įŽäŊ䏿
https://github.com/kawre/leetcode.nvim/assets/69250723/aee6584c-e099-4409-b114-123cb32b7563
> [!CAUTION]
> This plugin has been primarily tested with `Java`.
> If you encounter any errors while using other languages,
> please open an issue to report them.
## ⨠Features
- đ an intuitive dashboard for effortless navigation within [leetcode.nvim]
- đ question description formatting for a better readability
- đ [LeetCode] profile statistics within [Neovim]
- đ support for daily and random questions
- đž caching for optimized performance
## đŦ Requirements
- [Neovim] >= 0.9.0
- [telescope.nvim]
- [nui.nvim]
- [tree-sitter-html] _**(optional, but highly recommended)**_
used for formatting the question description.
Can be installed with [nvim-treesitter].
- [nvim-notify] _**(optional)**_
- [Nerd Font][nerd-font] & [nvim-web-devicons] _**(optional)**_
## đĻ Installation
- [lazy.nvim]
```lua
{
"kawre/leetcode.nvim",
build = ":TSUpdate html",
dependencies = {
"nvim-telescope/telescope.nvim",
"nvim-lua/plenary.nvim", -- required by telescope
"MunifTanjim/nui.nvim",
-- optional
"nvim-treesitter/nvim-treesitter",
"rcarriga/nvim-notify",
"nvim-tree/nvim-web-devicons",
},
opts = {
-- configuration goes here
},
}
```
## đ ī¸ Configuration
To see full configuration types see [template.lua](./lua/leetcode/config/template.lua)
### âī¸ default configuration
```lua
{
---@type string
arg = "leetcode.nvim",
---@type lc.lang
lang = "cpp",
cn = { -- leetcode.cn
enabled = false, ---@type boolean
translator = true, ---@type boolean
translate_problems = true, ---@type boolean
},
---@type lc.storage
storage = {
home = vim.fn.stdpath("data") .. "/leetcode",
cache = vim.fn.stdpath("cache") .. "/leetcode",
},
---@type table