victorteokw / ac-html

Emacs auto complete source for html.
22 stars 9 forks source link

ac-compile-sources: Symbol's value as variable is void: ac-source-html-tag #36

Closed Pitometsu closed 8 years ago

Pitometsu commented 8 years ago

I installed ac-html via el-get, did

(defun init-setup-ac-for-html ()
  "Enable HTML sources for `auto-complete-mode'."
  (require 'ac-html)
  (require 'ac-html-default-data-provider)
  (ac-html-enable-data-provider 'ac-html-default-data-provider)
  (ac-html-setup)
  (make-local-variable 'ac-sources)
  (setq ac-sources (append '(ac-source-html-tag
                             ac-source-html-attr
                             ac-source-html-attrv)
                           ac-sources)))

(add-hook 'html-mode-hook 'init-setup-ac-for-html)
;; `web-mode' setup
(eval-after-load 'web-mode
  '(add-to-list 'web-mode-ac-sources-alist
                '("html" . (ac-source-html-tag
                            ac-source-html-attr
                            ac-source-html-attrv))))
 '(ac-modes
   (quote
    (emacs-lisp-mode lisp-mode lisp-interaction-mode slime-repl-mode c-mode cc-mode c++-mode java-mode malabar-mode clojure-mode scala-mode scheme-mode sclang-mode ocaml-mode tuareg-mode haskell-mode perl-mode cperl-mode python-mode ruby-mode enh-ruby-mode ecmascript-mode javascript-mode js-mode js2-mode php-mode css-mode makefile-mode sh-mode fortran-mode f90-mode ada-mode xml-mode sgml-mode ts-mode objc-mode web-mode)))

And got ac-compile-sources: Symbol's value as variable is void: ac-source-html-tag. What did do I wrong and why it not in your README?

Pitometsu commented 8 years ago

For html-mode everything just work.

Pitometsu commented 8 years ago

Hm... Now it works. Don't know, why, I nothing changed. Very strange. Close issue.

Pitometsu commented 8 years ago

No, not working: if I enable html-mode, then web-mode, in web-mode auto-complete working. But only for current buffer.

Pitometsu commented 8 years ago

Sorry, maybe old package used.