MiguelCastillo / Brackets-InteractiveLinter

Interactive linting for Brackets
Other
119 stars 26 forks source link

</source> is not needed #193

Open PercyButton opened 7 years ago

PercyButton commented 7 years ago

Linter prompted: Tag must be paired, Missing: [ ] with the following code:

        <video id="1" width="560" height="315" controls>
            <source src="new/How the Tesla Model S is Made _ Tesla Motors Part 1 (WIRED).mp4" type="video/mp4">            
            Please upgrade your browser!
        </video>

But the close tag is not necessary: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/source

JackDinn commented 6 years ago

Hi, so what was the answer here as i have exactly the same problem. Iv just started using brackets and learning html,css,js,php and would appreciated some advice. Thx.

MiguelCastillo commented 6 years ago

Oh yeah for sure. Always close tags, even if not required. Those cases are the exception and from my experience you would be doing it because you can and not because you should. Its kinda like using loose equal comparison vs strict comparison in JavaScript. Its allowed, but don't do it. :)

Hope that helps.

JackDinn commented 6 years ago

did i do this wrong ? i tried closing the tags, the interactive linter is ok now (showing green) but the default syntax checker still shows RED , im assuming a lot here cos iv only just started out but heres a screen shot https://imgur.com/W7wuUOI

MiguelCastillo commented 6 years ago

does the default checker ever go away? what if you remove the video tag - just for testing purposes?

JackDinn commented 6 years ago

well i was not 100% sure if it was actually the default linter/checker or not, it could have been one of my extensions since i added a load that looked like id be wanting them before i even used brackets. So i disabled all the addons. Looks like it is the default error checker and yes it does go away when i remove the closing tag. Must be a setting to turn the default syntax checking off somewhere? maybe :-/ 4 SS's here https://imgur.com/a/U8xHi