I am trying to find the <!DOCTYPE html> tag of a webpage with JS.
For example if the declaration was <!DOCTYPE foo> I want to be able to find that with JS.
I do not want jquery for this.
I am trying to write somthing like on
this W3schools Link
But it does not work...