RubyLouvre/avalon

View on GitHub
src/dom/val/getDuplexType.js

Summary

Maintainability
A
0 mins
Test Coverage
import { rcheckedType } from '../rcheckedType'
export function getDuplexType(elem) {
    var ret = elem.tagName.toLowerCase()
    if (ret === 'input') {
        return rcheckedType.test(elem.type) ? 'checked' : elem.type
    }
    return ret
}