yosssi/ace

Is `script defer` broken...?

jpap opened this issue · 1 comments

jpap commented

Using the defer keyword in a script definition as follows,

script defer src="script.js" type="text/javascript"

renders incorrectly,

<script>defer src="script.js" type="text/javascript"</script>

which should instead be

<script defer src="script.js" type="text/javascript"></script>

.

Further, if you place the defer keyword at the end, Ace thinks that it is the script. The code

script src="script.js" type="text/javascript" defer

renders incorrectly as

<script src="script.js" type="text/javascript">defer</script>

when it should be

<script src="script.js" type="text/javascript" defer></script>

.

jpap commented

Curiously, if I write,

script defer="" src="script.js" type="text/javascript"

then it renders correctly, and without the ="" part too.

Is this by design? If so, it would be great to include in the documentation!