Content deleted Content added
Mike Dillon (talk | contribs) m expand tag name list |
Mike Dillon (talk | contribs) move DOM element creation into a function |
||
Line 4:
var stringType = typeof '';
var functionType = typeof function() {};
// Creates the DOM element
var createElement = function(name) {
var elem = document.createElement(name);
return elem;
};
// Detects if the first element is a hash of attributes and if so,
Line 53 ⟶ 59:
// Return the function that creates new DOM elements
return function() {
var elem =
// Process attribute hash, if any and skip the argument count returned
|