I know we can use
const a = document.createElement('a').
But what I'm trying is
const a = new HTMLAnchorElement()
However this will throw the following Exception :
Uncaught TypeError: Illegal constructor
What am I doing wrong ?
I know we can use
const a = document.createElement('a').
But what I'm trying is
const a = new HTMLAnchorElement()
However this will throw the following Exception :
Uncaught TypeError: Illegal constructor
What am I doing wrong ?