GithubHelp home page GithubHelp logo

coc-lightbulb-'s Introduction

coc-lightbulb

Code action 💡 for coc.nvim

Show a lightbulb if there are available codeActions for current cursor position

demo

Install

:CocInstall coc-lightbulb

Configuration

name default description
lightbulb.only [] Array of codeActionKind used for filtering
lightbulb.excludeFiletypes [] Disable lightbulb in these filetyps
lightbulb.enableVirtualText true Whether to show virtual text(neovim only)
lightbulb.virtualTextPosition auto Virtual text position
lightbulb.virtualTextPriority 50 Priority of virtual text
lightbulb.enableSign false Whether to show sign
lightbulb.signPriority 20 Priority of sign
lightbulb.followDiagnostic true Don't show lightbulb when b:coc_diagnostic_disable equal to 1
{
  "lightbulb.text": {
    // nerd-font: nf-mdi-lightbulb, text used when there're code actions
    "default": "",
    // nerd-font: nf-mdi-auto_fix, text used when there're code actions and quickfix exists
    "quickfix": ""
  }
}

Usage

  1. The variable b:coc_lightbulb_status will always be set and you can use it for the statusline

  2. How to disable lightbulb for current buffer ?

let b:coc_lightbulb_disable = 1
  1. highlights

by default

" virtual text
hi default LightBulbDefaultVirtualText guifg=#FDD164
hi default link LightBulbQuickFixVirtualText LightBulbDefaultVirtualText
" sign
hi default LightBulbDefaultSign guifg=#FDD164
hi default link LightBulbQuickFixSign LightBulbDefaultSign
" for numhl, you can set LightBulbDefaultSignLine, LightBulbQuickFixSignLine

License

MIT


This extension is built with create-coc-extension

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.