mudgen / webscript

Webscript is a Javascript library for creating DOM elements. Use it to create web applications. It is like HTML but it is Javascript. It is designed to work with existing libraries.
https://mudgen.github.io/webscript/docs/
MIT License
86 stars 9 forks source link

How to use id ? #14

Open dinh opened 4 years ago

dinh commented 4 years ago

<span id="myId">Some text</span> translated to span.idmyId`Some text trigger an error. How about tag attributes like` or ?

mudgen commented 4 years ago

Hi there!

How did you get that translation?

If I go to the translation website html2webscript and input <span id="myId">Some text</span> I get this result:

span.id`myId``Some text`

That code is correct and works.

All tag attributes like Name work. They work because Webscript uses proxies so there are no name clashes with prototypical property names.

Any other questions?