JSFiddle - React, Tailwind, and code Playground

by yijiang

JavaScript

var supported = {date: false, number: false, time: false, month: false, week: false}, 
    tester = document.createElement('input'), 
    output = '';

for(var i in supported){
    tester.type = i;
    if(tester.type === i){
        supported[i] = true;
    }
    
    output += '<p>' + i + ': ' + supported[i] + '</p>';
}

document.body.innerHTML = output;