GithubHelp home page GithubHelp logo

company-web's Introduction

Company-web

Build Status MELPA MELPA Stable

Company-web is an alternative emacs plugin for autocompletion in html-mode, web-mode, jade-mode, slim-mode and use data of ac-html. It uses company-mode.

Setup

Install company via Melpa.

Add the following to your emacs-config:

(require 'company)                                   ; load company mode
(require 'company-web-html)                          ; load company mode html backend
;; and/or
(require 'company-web-jade)                          ; load company mode jade backend
(require 'company-web-slim)                          ; load company mode slim backend

;; you may key bind, for example for web-mode:
(define-key web-mode-map (kbd "C-'") 'company-web-html)

Additionally you may want install ac-html-csswatcher and ac-html-bootstrap.

Possible improvements of company-mode

;; (setq company-minimum-prefix-length 0)            ; WARNING, probably you will get perfomance issue if min len is 0!
(setq company-tooltip-limit 20)                      ; bigger popup window
(setq company-tooltip-align-annotations 't)          ; align annotations to the right tooltip border
(setq company-idle-delay .3)                         ; decrease delay before autocompletion popup shows
(setq company-begin-commands '(self-insert-command)) ; start autocompletion only after typing
(global-set-key (kbd "C-c /") 'company-files)        ; Force complete file names on "C-c /" key

Also very useful is package company-statistics for sort candidates using completion history.

Only use company-mode with company-web-html in web-mode

By default company-mode loads every backend it has. If you want to only have company-mode enabled in web-mode add the following to your emacs-config:

(add-hook 'web-mode-hook (lambda ()
                          (set (make-local-variable 'company-backends) '(company-web-html))
                          (company-mode t)))

Emmet integration

Company-web support integration with emmet-mode and emmet-preview and add some advices to make C-g and RET keys work properly.

emmet with company-web

Color customization

(custom-set-faces
 '(company-preview
   ((t (:foreground "darkgray" :underline t))))
 '(company-preview-common
   ((t (:inherit company-preview))))
 '(company-tooltip
   ((t (:background "lightgray" :foreground "black"))))
 '(company-tooltip-selection
   ((t (:background "steelblue" :foreground "white"))))
 '(company-tooltip-common
   ((((type x)) (:inherit company-tooltip :weight bold))
    (t (:inherit company-tooltip))))
 '(company-tooltip-common-selection
   ((((type x)) (:inherit company-tooltip-selection :weight bold))
    (t (:inherit company-tooltip-selection)))))

If you want to add Tern completion support in web-mode with company-mode. You can add this into your .emacs:

(defun my-web-mode-hook ()
  "Hook for `web-mode'."
    (set (make-local-variable 'company-backends)
         '(company-tern company-web-html company-yasnippet company-files)))

(add-hook 'web-mode-hook 'my-web-mode-hook)

;; Enable JavaScript completion between <script>...</script> etc.
(advice-add 'company-tern :before
            #'(lambda (&rest _)
                (if (equal major-mode 'web-mode)
                    (let ((web-mode-cur-language
                          (web-mode-language-at-pos)))
                      (if (or (string= web-mode-cur-language "javascript")
                              (string= web-mode-cur-language "jsx"))
                          (unless tern-mode (tern-mode))
                        (if tern-mode (tern-mode -1)))))))

;; manual autocomplete
(define-key web-mode-map (kbd "M-SPC") 'company-complete)

Related projects

You may be interested in next projects:

company-web's People

Contributors

jcs090218 avatar osv avatar stardiviner avatar syohex avatar tottoto avatar wyuenho avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

company-web's Issues

Cann't complete with the `-`

Hi company-web maintainer:

Recently I found the problem with auto completetion in company-web-html for auto completing the css style of some thing like :border- which just can be use border without the -.

For more details are:

For complete the border-width .

  1. auto complete succeed :
Type `border` and then `M-x company-web-html` immediatly
  1. auto complete with none candidates:
Type `border-` and then `M-x company-web-html` 

Focus on the only little difference between them are that containing the - character.

Hope for you help! 👍

How to make it work with company-yasnippet?

I am now writing a .html file using Bootstrap, so I need completion like class="btn " ship with a file named .csswatcher

if I set company-backends to (company-web-html), every thing works fine:

截屏2023-01-26 17 41 15

But when it was set to (company-yasnippet company-web-html), it doesn't auto complete the class="btn-" but the template works

截屏2023-01-26 17 53 16

I don't know the right way in doing so, and I also use the lsp-mode with emmet-ls html-ls, but they don't provide completion at all

Thanks in advance

emmet support

emmet completion:

  • tags after >+^ symbols
  • attribute completion after [
  • Dot . - complete div's class
  • # - id (div's id if no tag)

A very long-running re-search-backward call in company-web-html

I have this anomalous case where writing " (quote) in a .tpl file (PHP smarty template) with web-mode and company-web enabled (in spacemacs, ectually) triggers a very long-running re-search-backward call on the buffer. Had to interrupt with kill -USR2 $emacsid to get backtrace, C-g didn't help.

The file is 64K long with ~1K lines. I can provide you with the file (privately as it is company property) if that is needed.

The backtrace is:

Debugger entered--Lisp error: (quit)
  re-search-backward("\\(?:<[[:space:]]*[[:alnum:]_-][^>]*[[:space:]]+\\(.*\\)\\)\\=" nil t)
  looking-back("<[[:space:]]*[[:alnum:]_-][^>]*[[:space:]]+\\(.*\\)" nil)
  company-grab("<[[:space:]]*[[:alnum:]_-][^>]*[[:space:]]+\\(.*\\)" 1)
  company-web-html(prefix)
  apply(company-web-html prefix)
  company--force-sync(company-web-html (prefix) company-web-html)
  company--multi-backend-adapter((company-web-html company-css) prefix)
  apply(company--multi-backend-adapter (company-web-html company-css) prefix)
  company-call-backend-raw(prefix)
  apply(company-call-backend-raw prefix)
  company--force-sync(company-call-backend-raw (prefix) (company-web-html company-css))
  company-call-backend(prefix)
  company--occurrence-predicate()
  #[257 "\30524\300b\210\306�\301\307#\2053`\302=\204�\310 \311\312\313\314\315�!\316\"\317$\216\320 )\262�\203�\321\305\307\"\210\202�0\205G\303�\f\302\312\224\312\225#B\303\242B\240\210\307\207" [40976 45290 42516 (((#("a" 0 1 (annotation "html")) . 1261))) company-occurrence-weight-function done search-forward t match-data make-byte-code 0 "\301\300\302\"\207" vconcat vector [set-match-data evaporate] 3 company--occurrence-predicate throw] 8 "\n\n(fn CANDIDATE)"](#("b" 0 1 (annotation "html")))
  cl-delete(nil (#("a" 0 1 (annotation "html")) #("abbr" 0 4 (annotation "html")) #("acronym" 0 7 (annotation "html")) #("address" 0 7 (annotation "html")) #("applet" 0 6 (annotation "html")) #("area" 0 4 (annotation "html")) #("article" 0 7 (annotation "html")) #("aside" 0 5 (annotation "html")) #("audio" 0 5 (annotation "html")) #("b" 0 1 (annotation "html")) #("base" 0 4 (annotation "html")) #("basefont" 0 8 (annotation "html")) #("bdi" 0 3 (annotation "html")) #("bdo" 0 3 (annotation "html")) #("bgsound" 0 7 (annotation "html")) #("big" 0 3 (annotation "html")) #("blink" 0 5 (annotation "html")) #("blockquote" 0 10 (annotation "html")) #("body" 0 4 (annotation "html")) #("br" 0 2 (annotation "html")) #("button" 0 6 (annotation "html")) #("canvas" 0 6 (annotation "html")) #("caption" 0 7 (annotation "html")) #("center" 0 6 (annotation "html")) #("cite" 0 4 (annotation "html")) #("code" 0 4 (annotation "html")) #("col" 0 3 (annotation "html")) #("colgroup" 0 8 (annotation "html")) #("command" 0 7 (annotation "html")) #("content" 0 7 (annotation "html")) #("data" 0 4 (annotation "html")) #("datalist" 0 8 (annotation "html")) #("dd" 0 2 (annotation "html")) #("decorator" 0 9 (annotation "html")) #("del" 0 3 (annotation "html")) #("details" 0 7 (annotation "html")) #("dfn" 0 3 (annotation "html")) #("dialog" 0 6 (annotation "html")) #("dir" 0 3 (annotation "html")) #("div" 0 3 (annotation "html")) #("dl" 0 2 (annotation "html")) #("dt" 0 2 (annotation "html")) #("element" 0 7 (annotation "html")) #("em" 0 2 (annotation "html")) #("embed" 0 5 (annotation "html")) #("fieldset" 0 8 (annotation "html")) #("figcaption" 0 10 (annotation "html")) #("figure" 0 6 (annotation "html")) #("font" 0 4 (annotation "html")) #("footer" 0 6 (annotation "html")) ...) :if #[257 "\30524\300b\210\306�\301\307#\2053`\302=\204�\310 \311\312\313\314\315�!\316\"\317$\216\320 )\262�\203�\321\305\307\"\210\202�0\205G\303�\f\302\312\224\312\225#B\303\242B\240\210\307\207" [40976 45290 42516 (((#("a" 0 1 (annotation "html")) . 1261))) company-occurrence-weight-function done search-forward t match-data make-byte-code 0 "\301\300\302\"\207" vconcat vector [set-match-data evaporate] 3 company--occurrence-predicate throw] 8 "\n\n(fn CANDIDATE)"])
  apply(cl-delete nil (#("a" 0 1 (annotation "html")) #("abbr" 0 4 (annotation "html")) #("acronym" 0 7 (annotation "html")) #("address" 0 7 (annotation "html")) #("applet" 0 6 (annotation "html")) #("area" 0 4 (annotation "html")) #("article" 0 7 (annotation "html")) #("aside" 0 5 (annotation "html")) #("audio" 0 5 (annotation "html")) #("b" 0 1 (annotation "html")) #("base" 0 4 (annotation "html")) #("basefont" 0 8 (annotation "html")) #("bdi" 0 3 (annotation "html")) #("bdo" 0 3 (annotation "html")) #("bgsound" 0 7 (annotation "html")) #("big" 0 3 (annotation "html")) #("blink" 0 5 (annotation "html")) #("blockquote" 0 10 (annotation "html")) #("body" 0 4 (annotation "html")) #("br" 0 2 (annotation "html")) #("button" 0 6 (annotation "html")) #("canvas" 0 6 (annotation "html")) #("caption" 0 7 (annotation "html")) #("center" 0 6 (annotation "html")) #("cite" 0 4 (annotation "html")) #("code" 0 4 (annotation "html")) #("col" 0 3 (annotation "html")) #("colgroup" 0 8 (annotation "html")) #("command" 0 7 (annotation "html")) #("content" 0 7 (annotation "html")) #("data" 0 4 (annotation "html")) #("datalist" 0 8 (annotation "html")) #("dd" 0 2 (annotation "html")) #("decorator" 0 9 (annotation "html")) #("del" 0 3 (annotation "html")) #("details" 0 7 (annotation "html")) #("dfn" 0 3 (annotation "html")) #("dialog" 0 6 (annotation "html")) #("dir" 0 3 (annotation "html")) #("div" 0 3 (annotation "html")) #("dl" 0 2 (annotation "html")) #("dt" 0 2 (annotation "html")) #("element" 0 7 (annotation "html")) #("em" 0 2 (annotation "html")) #("embed" 0 5 (annotation "html")) #("fieldset" 0 8 (annotation "html")) #("figcaption" 0 10 (annotation "html")) #("figure" 0 6 (annotation "html")) #("font" 0 4 (annotation "html")) #("footer" 0 6 (annotation "html")) ...) :if #[257 "\30524\300b\210\306�\301\307#\2053`\302=\204�\310 \311\312\313\314\315�!\316\"\317$\216\320 )\262�\203�\321\305\307\"\210\202�0\205G\303�\f\302\312\224\312\225#B\303\242B\240\210\307\207" [40976 45290 42516 (((#("a" 0 1 (annotation "html")) . 1261))) company-occurrence-weight-function done search-forward t match-data make-byte-code 0 "\301\300\302\"\207" vconcat vector [set-match-data evaporate] 3 company--occurrence-predicate throw] 8 "\n\n(fn CANDIDATE)"] nil)
  cl-delete-if(#[257 "\30524\300b\210\306�\301\307#\2053`\302=\204�\310 \311\312\313\314\315�!\316\"\317$\216\320 )\262�\203�\321\305\307\"\210\202�0\205G\303�\f\302\312\224\312\225#B\303\242B\240\210\307\207" [40976 45290 42516 (((#("a" 0 1 (annotation "html")) . 1261))) company-occurrence-weight-function done search-forward t match-data make-byte-code 0 "\301\300\302\"\207" vconcat vector [set-match-data evaporate] 3 company--occurrence-predicate throw] 8 "\n\n(fn CANDIDATE)"] (#("a" 0 1 (annotation "html")) #("abbr" 0 4 (annotation "html")) #("acronym" 0 7 (annotation "html")) #("address" 0 7 (annotation "html")) #("applet" 0 6 (annotation "html")) #("area" 0 4 (annotation "html")) #("article" 0 7 (annotation "html")) #("aside" 0 5 (annotation "html")) #("audio" 0 5 (annotation "html")) #("b" 0 1 (annotation "html")) #("base" 0 4 (annotation "html")) #("basefont" 0 8 (annotation "html")) #("bdi" 0 3 (annotation "html")) #("bdo" 0 3 (annotation "html")) #("bgsound" 0 7 (annotation "html")) #("big" 0 3 (annotation "html")) #("blink" 0 5 (annotation "html")) #("blockquote" 0 10 (annotation "html")) #("body" 0 4 (annotation "html")) #("br" 0 2 (annotation "html")) #("button" 0 6 (annotation "html")) #("canvas" 0 6 (annotation "html")) #("caption" 0 7 (annotation "html")) #("center" 0 6 (annotation "html")) #("cite" 0 4 (annotation "html")) #("code" 0 4 (annotation "html")) #("col" 0 3 (annotation "html")) #("colgroup" 0 8 (annotation "html")) #("command" 0 7 (annotation "html")) #("content" 0 7 (annotation "html")) #("data" 0 4 (annotation "html")) #("datalist" 0 8 (annotation "html")) #("dd" 0 2 (annotation "html")) #("decorator" 0 9 (annotation "html")) #("del" 0 3 (annotation "html")) #("details" 0 7 (annotation "html")) #("dfn" 0 3 (annotation "html")) #("dialog" 0 6 (annotation "html")) #("dir" 0 3 (annotation "html")) #("div" 0 3 (annotation "html")) #("dl" 0 2 (annotation "html")) #("dt" 0 2 (annotation "html")) #("element" 0 7 (annotation "html")) #("em" 0 2 (annotation "html")) #("embed" 0 5 (annotation "html")) #("fieldset" 0 8 (annotation "html")) #("figcaption" 0 10 (annotation "html")) #("figure" 0 6 (annotation "html")) #("font" 0 4 (annotation "html")) #("footer" 0 6 (annotation "html")) ...))
  company-sort-by-occurrence((#("a" 0 1 (annotation "html")) #("abbr" 0 4 (annotation "html")) #("acronym" 0 7 (annotation "html")) #("address" 0 7 (annotation "html")) #("applet" 0 6 (annotation "html")) #("area" 0 4 (annotation "html")) #("article" 0 7 (annotation "html")) #("aside" 0 5 (annotation "html")) #("audio" 0 5 (annotation "html")) #("b" 0 1 (annotation "html")) #("base" 0 4 (annotation "html")) #("basefont" 0 8 (annotation "html")) #("bdi" 0 3 (annotation "html")) #("bdo" 0 3 (annotation "html")) #("bgsound" 0 7 (annotation "html")) #("big" 0 3 (annotation "html")) #("blink" 0 5 (annotation "html")) #("blockquote" 0 10 (annotation "html")) #("body" 0 4 (annotation "html")) #("br" 0 2 (annotation "html")) #("button" 0 6 (annotation "html")) #("canvas" 0 6 (annotation "html")) #("caption" 0 7 (annotation "html")) #("center" 0 6 (annotation "html")) #("cite" 0 4 (annotation "html")) #("code" 0 4 (annotation "html")) #("col" 0 3 (annotation "html")) #("colgroup" 0 8 (annotation "html")) #("command" 0 7 (annotation "html")) #("content" 0 7 (annotation "html")) #("data" 0 4 (annotation "html")) #("datalist" 0 8 (annotation "html")) #("dd" 0 2 (annotation "html")) #("decorator" 0 9 (annotation "html")) #("del" 0 3 (annotation "html")) #("details" 0 7 (annotation "html")) #("dfn" 0 3 (annotation "html")) #("dialog" 0 6 (annotation "html")) #("dir" 0 3 (annotation "html")) #("div" 0 3 (annotation "html")) #("dl" 0 2 (annotation "html")) #("dt" 0 2 (annotation "html")) #("element" 0 7 (annotation "html")) #("em" 0 2 (annotation "html")) #("embed" 0 5 (annotation "html")) #("fieldset" 0 8 (annotation "html")) #("figcaption" 0 10 (annotation "html")) #("figure" 0 6 (annotation "html")) #("font" 0 4 (annotation "html")) #("footer" 0 6 (annotation "html")) ...))
  company--transform-candidates((#("a" 0 1 (annotation "html")) #("abbr" 0 4 (annotation "html")) #("acronym" 0 7 (annotation "html")) #("address" 0 7 (annotation "html")) #("applet" 0 6 (annotation "html")) #("area" 0 4 (annotation "html")) #("article" 0 7 (annotation "html")) #("aside" 0 5 (annotation "html")) #("audio" 0 5 (annotation "html")) #("b" 0 1 (annotation "html")) #("base" 0 4 (annotation "html")) #("basefont" 0 8 (annotation "html")) #("bdi" 0 3 (annotation "html")) #("bdo" 0 3 (annotation "html")) #("bgsound" 0 7 (annotation "html")) #("big" 0 3 (annotation "html")) #("blink" 0 5 (annotation "html")) #("blockquote" 0 10 (annotation "html")) #("body" 0 4 (annotation "html")) #("br" 0 2 (annotation "html")) #("button" 0 6 (annotation "html")) #("canvas" 0 6 (annotation "html")) #("caption" 0 7 (annotation "html")) #("center" 0 6 (annotation "html")) #("cite" 0 4 (annotation "html")) #("code" 0 4 (annotation "html")) #("col" 0 3 (annotation "html")) #("colgroup" 0 8 (annotation "html")) #("command" 0 7 (annotation "html")) #("content" 0 7 (annotation "html")) #("data" 0 4 (annotation "html")) #("datalist" 0 8 (annotation "html")) #("dd" 0 2 (annotation "html")) #("decorator" 0 9 (annotation "html")) #("del" 0 3 (annotation "html")) #("details" 0 7 (annotation "html")) #("dfn" 0 3 (annotation "html")) #("dialog" 0 6 (annotation "html")) #("dir" 0 3 (annotation "html")) #("div" 0 3 (annotation "html")) #("dl" 0 2 (annotation "html")) #("dt" 0 2 (annotation "html")) #("element" 0 7 (annotation "html")) #("em" 0 2 (annotation "html")) #("embed" 0 5 (annotation "html")) #("fieldset" 0 8 (annotation "html")) #("figcaption" 0 10 (annotation "html")) #("figure" 0 6 (annotation "html")) #("font" 0 4 (annotation "html")) #("footer" 0 6 (annotation "html")) ...))
  company--postprocess-candidates((#("a" 0 1 (annotation "html")) #("abbr" 0 4 (annotation "html")) #("acronym" 0 7 (annotation "html")) #("address" 0 7 (annotation "html")) #("applet" 0 6 (annotation "html")) #("area" 0 4 (annotation "html")) #("article" 0 7 (annotation "html")) #("aside" 0 5 (annotation "html")) #("audio" 0 5 (annotation "html")) #("b" 0 1 (annotation "html")) #("base" 0 4 (annotation "html")) #("basefont" 0 8 (annotation "html")) #("bdi" 0 3 (annotation "html")) #("bdo" 0 3 (annotation "html")) #("bgsound" 0 7 (annotation "html")) #("big" 0 3 (annotation "html")) #("blink" 0 5 (annotation "html")) #("blockquote" 0 10 (annotation "html")) #("body" 0 4 (annotation "html")) #("br" 0 2 (annotation "html")) #("button" 0 6 (annotation "html")) #("canvas" 0 6 (annotation "html")) #("caption" 0 7 (annotation "html")) #("center" 0 6 (annotation "html")) #("cite" 0 4 (annotation "html")) #("code" 0 4 (annotation "html")) #("col" 0 3 (annotation "html")) #("colgroup" 0 8 (annotation "html")) #("command" 0 7 (annotation "html")) #("content" 0 7 (annotation "html")) #("data" 0 4 (annotation "html")) #("datalist" 0 8 (annotation "html")) #("dd" 0 2 (annotation "html")) #("decorator" 0 9 (annotation "html")) #("del" 0 3 (annotation "html")) #("details" 0 7 (annotation "html")) #("dfn" 0 3 (annotation "html")) #("dialog" 0 6 (annotation "html")) #("dir" 0 3 (annotation "html")) #("div" 0 3 (annotation "html")) #("dl" 0 2 (annotation "html")) #("dt" 0 2 (annotation "html")) #("element" 0 7 (annotation "html")) #("em" 0 2 (annotation "html")) #("embed" 0 5 (annotation "html")) #("fieldset" 0 8 (annotation "html")) #("figcaption" 0 10 (annotation "html")) #("figure" 0 6 (annotation "html")) #("font" 0 4 (annotation "html")) #("footer" 0 6 (annotation "html")) ...))
  company-calculate-candidates("")
  company--begin-new()
  company--perform()
  company-auto-begin()
  company-idle-begin(#<buffer usertasks.tpl> #<window 572 on usertasks.tpl> 18636 42516)
  apply(company-idle-begin (#<buffer usertasks.tpl> #<window 572 on usertasks.tpl> 18636 42516))
  timer-event-handler([t 23025 37510 864716 nil company-idle-begin (#<buffer usertasks.tpl> #<window 572 on usertasks.tpl> 18636 42516) nil 0])

Enable tern between <script> tags example in README incorrect (maybe?)

The snippet in the README is:

;; Enable JavaScript completion between <script>...</script> etc.
(defadvice company-tern (before web-mode-set-up-ac-sources activate)
  "Set `tern-mode' based on current language before running company-tern."
  (if (equal major-mode 'web-mode)
      (let ((web-mode-cur-language
             (web-mode-language-at-pos)))
        (if (or (string= web-mode-cur-language "javascript")
               (string= web-mode-cur-language "jsx")
               )
            (unless tern-mode (tern-mode))
          (if tern-mode (tern-mode))))))

I believe the purpose of the last line is to disable tern-mode if we're not in a javascript section. If that's the case, the line should read (if tern-mode (tern-mode -1)))))).

If that's the case I can make the change if you want me to, or you can go ahead.

Thanks for a great lib!

TODO: HAML support

ac-html support have HAML template support, good to add for company-web too.

Html head-->style-->area can not be completed of css.

Hi company-web maintainer:

This problem was similar with Cann't complete with the - and I think this was as well the bug
in regexp but it is of area detected.

The details is below:

  • Assume the html area was like:
<html>
    <head>
        <style>
            .class{
              border.......
            }
        </style>
    </head>
    <body>
    </body>
</html>
  • follow the uppon DEMO, I want to auto complete border for border-width with the company-mode
    messeage "No completion found" :
   +--------------------------------------------------+
   |   <html>                                         |
   |     <head>                                       |
   |       <style>                                    |
   |          .class { border-    <....    }          |
   |       </style>                   .               |
   |                                  .               |
   |                                  .               |
   |                              .....               |
   |                              .                   |
   |                              .                   |
   |                              .                   |
   |                              .                   |
   |                              .                   |
   |                              .                   |
   |                              .                   |
   |                       ........                   |
   |                       .                          |                                                     
   |                       .                          |                                                     
   |                       .                          |                                                     
   |                       .                          |                                                     
   |                       .                          |                                                     
   |                       .                          |                                                     
   |-----------------------.--------------------------|                                                     
   | <test.html> u(unix)  <web-mode>       13:00      |                                                     
   |-----------------------.--------------------------|                                                     
   | M-x: company-complete . (M-/)                    |                                                     
   |                                                  |
   |                                                  |
   |                                                  |
   |      No completion.                              |
   |                                                  |
   |                                                  |
   +--------------------------------------------------+


Can't complete on `<`

I am using spacemacs where I want to complete when I type the < character. But it doesn't complete. The company-minimum-prefix-length for me is 1. So, I have to type an extra alphabet after < to get completion. How do I resolve this?
See: syl20bnr/spacemacs#8222

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.