Giter Site home page Giter Site logo

lvim's People

Contributors

esso0428 avatar

Watchers

 avatar  avatar

lvim's Issues

`nvim-html-css` doesn't load when used with nVim v0.10.0

EDIT

I think this is happening because the plugin loads prematurely. I can manually get user_config via Lua once cmp has loaded without any issues.

Adding nvim-cmp as the dependency of nvim-html-css makes it load successfully, but the cmp source is still unavailable:

# ready source names                                                                                                                                                                            
- async_path                                                                                                                                                                                    
- nvim_lsp:html                                                                                                                                                                                 
                                                                                                                                                                                                
# unavailable source names                                                                                                                                                                      
- html-css

ORIGINAL MESSAGE

Sorry for creating this in the wrong repo, but the "Issues" section is disabled at ESSO0428/nvim-html-css.

This check:

if not vim.tbl_contains(self.option.enable_on, vim.bo.filetype) then

Fails with:

Error executing vim.schedule lua callback: vim/shared.lua:0: t: expected table, got nil
stack traceback:                                                                                                                                                                                
        [C]: in function 'error'                                                                                                                                                                
        vim/shared.lua: in function 'validate'                                                                                                                                                  
        vim/shared.lua: in function 'tbl_contains'                                                                                                                                              
        ...ocal/share/nvim/lazy/nvim-html-css/lua/html-css/init.lua:327: in function ''                                                                                                         
        vim/_editor.lua: in function ''                                                                                                                                                         
        vim/_editor.lua: in function <vim/_editor.lua:0>

Plugin is installed with default settings, nvim-cmp source added. Here is the content of self at the time:

{                                                                                                                                                                                               
  after_inert_before_update = true,                                                                                                                                                             
  cached_local_css_data = {},                                                                                                                                                                   
  embedded = "",                                                                                                                                                                                
  enable_file_patterns = { "*.html" },                                                                                                                                                          
  enable_on = {},                                                                                                                                                                               
  file_extensions = {},                                                                                                                                                                         
  href_links = {},                                                                                                                                                                              
  ids = {},                                                                                                                                                                                     
  isRemote = "^https?://",                                                                                                                                                                      
  items = {},                                                                                                                                                                                   
  last_html_buffer = 2,                                                                                                                                                                         
  local_classes = {},                                                                                                                                                                           
  local_css_file_mod_times = {},                                                                                                                                                                
  local_file = "",                                                                                                                                                                              
  local_ids = {},                                                                                                                                                                               
  local_style_sheets = {},                                                                                                                                                                      
  option = {},                                                                                                                                                                                  
  remote = "",                                                                                                                                                                                  
  remote_classes = {},                                                                                                                                                                          
  remote_ids = {},                                                                                                                                                                              
  remote_item_write = "",                                                                                                                                                                       
  remote_style_sheets = {},                                                                                                                                                                     
  source_name = "html-css",                                                                                                                                                                     
  style_sheets = {},                                                                                                                                                                            
  update_done = "",                                                                                                                                                                             
  user_config = {},                                                                                                                                                                             
  <metatable> = {                                                                                                                                                                               
    __index = {                                                                                                                                                                                 
      complete = <function 1>,                                                                                                                                                                  
      is_available = <function 2>,                                                                                                                                                              
      new = <function 3>,                                                                                                                                                                       
      update_completion_data = <function 4>                                                                                                                                                     
    }                                                                                                                                                                                           
  }                                                                                                                                                                                             
}

...and the relevant snippet from cmp config:

{
    name = 'html-css',
    option = {
        enable_on = {
            "htmldjango",
            "html",
        },
        enable_file_patterns = { "*.html" },
        file_extensions = { "css" },
        style_sheets = {}
    }
}

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.