Skip to content

Commit

Permalink
Update: add link preload "as" to HTMLAttributes type definition (#907)
Browse files Browse the repository at this point in the history
Link preloads support an as attribute. e.g.:

  <link rel="preload" href=foo.css as: "style" />
  <link rel="preload" href=foo.js as: "script" />

Update the HTMLAttributes type definition to avoid workarounds like:

  <link rel="preload" href=foo.css {...{ as: "style" }} />

https://developer.mozilla.org/en-US/docs/Web/HTML/Element/link
https://w3c.github.io/preload/#as-attribute
  • Loading branch information
niedzielski authored and developit committed Oct 12, 2017
1 parent 4d033d7 commit 4bc9af4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/preact.d.ts
Expand Up @@ -470,6 +470,7 @@ declare namespace JSX {
allowFullScreen?:boolean;
allowTransparency?:boolean;
alt?:string;
as?:string;
async?:boolean;
autocomplete?:string;
autofocus?:boolean;
Expand Down

0 comments on commit 4bc9af4

Please sign in to comment.