Autocomplete not working for classes & ids in html


I’m working with html and trying to get autocomplete to work for classes & ids already existing within the current document, but it’s only working if they are:

  1. defined in a style tags in the same document
  2. in a seperate open css document

and not if say I just have <span class="redbox"> somewhere and want redbox to appear as an autocomplete option.

It does however use strings,classes,etc as autocomplete options from the javascript code within the document. Autocomplete for javascript works just fine, as does for css files.

This is a fresh 1.0 install and ‘Include Completions From All Buffers’ is checked, so I’m not sure what I’m missing to enable this.

It sounds like this is the same idea?

The issue is that I’m not receiving class/id autocomplete suggestions at all for html, in the case of not using an external css sheet or first defining them in a style tag.

I’m assuming something is amiss because this person is able to do just that in this video (timestamped), wherein the class “container” appears as an autocomplete option due to it already being in the document just below.

he has autocomplete-plus package @ 3m30s

If you do the following, you should be able to replicate the behavior seen in the video:

  1. Launch Atom
  2. Open Settings View
  3. Go to the Packages tab
  4. Search for autocomplete-plus
  5. Click the Settings button for the autocomplete-plus package
  6. Ensure that “Enable Built-In Provider” is checked
  7. Ensure that Default Provider is set to “Fuzzy”

Thanks that did it. Downside is that I see a ton of other unrelated completions, but I can work with that for now.

1 Like

When atom will do this?:
Tihs editor is netbeans

The path completion I see is available with the autocomplete-paths package, to my understanding.

True… thank you! :smiley: