Detect whether a browser environment or user agent string supports input[type=date]
Browser code originates from this StackOverflow answer.
yarn add @ianwalter/supports-date-input
Browser:
import supportsDateInput from '@ianwalter/supports-date-input'
// Firefox 65:
supportsDateInput() // => true
// Internet Explorer:
supportsDateInput() // => false
Node.js:
const supportsDateInput = require('@ianwalter/supports-date-input')
// Firefox 65:
supportsDateInput(req.get('user-agent')) // => true
// Internet Explorer:
supportsDateInput(req.get('user-agent')) // => false
Hippocratic License - See LICENSE
Created by Ian Walter