Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf(cmp): remove redundant check for emmet-ls #2830

Merged
merged 1 commit into from
Jul 31, 2022

Conversation

rebuilt
Copy link
Collaborator

@rebuilt rebuilt commented Jul 20, 2022

…etion.

Description

Removes emmet logic from cmp.lua We were performing a check to see if emmet was active on every completion request. This slows down completion regardless of the filetype you're editing. Additionally, the emmet logic no longer works and is no longer required to get emmet running in lunarvim.

How Has This Been Tested?

If a user wants to run emmet, they can configure it like so:

lvim.plugins = {
  {
    "aca/emmet-ls",
    ft = {
      "html",
      "typescriptreact",
      "javascriptreact",
      "css",
      "sass",
      "scss",
      "less",
    },
  },
  {
    "jackieaskins/cmp-emmet",
    run = "npm run release",
  },
}

table.insert(lvim.builtin.cmp.sources, { name = "emmet" })
lvim.builtin.cmp.formatting.source_names["emmet"] = "(Emmet)"

@rebuilt rebuilt force-pushed the hotfix/remove-emmet-logic branch 8 times, most recently from 637031c to e48cb7c Compare July 20, 2022 06:47
@rebuilt
Copy link
Collaborator Author

rebuilt commented Jul 22, 2022

@kylo252 or @abzcoding Can you help me out with the stylua errors please?
It's complaining about files I have not touched:

 ./lua/lvim/core/telescope/custom-finders.lua
./lua/lvim/utils/git.lua
./tests/lvim/helpers.lua

I've tried many different variations of formatting and NOT formatting those files with stylua but I'm still getting errors.

Running stylua --config-path .stylua.toml . from the root directory: /home/nelson/.local/share/lunarvim/lvim only changes one file bufferline.lua.
Running stylua --config-path .stylua.toml ./lua/lvim/core/telescope/custom-finders.lua from the root directory makes no formatting changes to that file.
Running stylua custom-finders.lua from the folder it's in DOES modify the formatting for that file but not in a way that matches the github CI check.

I'm not sure how else to format those files so it passes CI

@kylo252
Copy link
Collaborator

kylo252 commented Jul 23, 2022

@rebuilt, you're probably using an older version of stylua 😅

it should be fine for other files that you haven't changed, if you rebase on rolling

@kylo252 kylo252 changed the title perf<cmp>: removes the check for the emmet language server from compl… perf(cmp): remove the check for emmet-ls Jul 23, 2022
@kylo252 kylo252 changed the title perf(cmp): remove the check for emmet-ls perf(cmp): remove redundant check for emmet-ls Jul 23, 2022
@kylo252 kylo252 force-pushed the hotfix/remove-emmet-logic branch from e48cb7c to 48cfb56 Compare July 31, 2022 12:32
@kylo252 kylo252 merged commit caac70d into rolling Jul 31, 2022
@kylo252 kylo252 deleted the hotfix/remove-emmet-logic branch September 20, 2022 10:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants