othree / html5.vim

HTML5 omnicomplete and syntax
http://www.vim.org/scripts/script.php?script_id=3236
934 stars 76 forks source link

"role" attribute #40

Closed cpixl closed 10 years ago

cpixl commented 10 years ago

Am I missing something or this plugin doesn't cover the ARIA role attribute? I can't get any completion on this attribute...

othree commented 10 years ago

It do have ARIA support and supports role attribute. I just test it. Do you disable it accidentally? (It can be disable in vimrc)

cpixl commented 10 years ago

I let just the default settings, you can look my .vimrc file at https://github.com/dan-silva/dotfiles/blob/master/vimrc

It looks like that the plugin checks the whole content to see if its a valid HTML5 file, and only after that it will work... everything, or nothing.

On the following sample its working:

<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title></title>
</head>
<body>
  <nav role="WORKING_HERE">
  </nav>
</body>
</html>

But on the following its not:

<div>
  <nav role="NOT_WORKING_HERE">
  </nav>
</div>

Although its not a valid HTML5 file, it's still HTML and I really need it because I'm using the file as a template for Angular.JS.

othree commented 10 years ago

I agree with you But not have much time to do the change.

othree commented 10 years ago

A quick walk around for this. Side effect is on root level, complete candidate will have almost everything.