nicojs / typed-html

TypeSafe HTML templates using TypeScript. No need to learn a template library.
333 stars 51 forks source link

Some attributes should accept boolean values #19

Open ratorx opened 3 years ago

ratorx commented 3 years ago

Some attributes are incorrectly marked as taking a string, whereas they should take boolean values.

As a concrete example, HtmlScriptTag.defer should take a boolean argument, rather than a string argument.

bebraw commented 3 years ago

Can you compile a list? Is there a definitive source for these? Would it be possible to consume the correct types from some another type definition for the DOM?

ratorx commented 3 years ago

Typescript has a list of generated DOM types as well as the source code for the generator available.

This seems like a good source of definitive APIs for this project. Perhaps a wrapper to the generator could be used to generate the specific type definitions needed by this project?