minus-squaremaster5o1@lemmy.nztoProgrammer Humor@lemmy.ml•Errorslinkfedilinkarrow-up0·edit-25 days agoMy assumption is that it’s setting up an object to map element selectors -> callbacks. var specialElementHandlers = { '#editor': function() { return true; } }; But yeah, could be something as var specialElementHandlers = Object.assign({}, defaultHandlers, { '#editor': function() { return true; } }; // missing closing parenthesis linkfedilink
My assumption is that it’s setting up an object to map element selectors -> callbacks.
var specialElementHandlers = { '#editor': function() { return true; } };
But yeah, could be something as
var specialElementHandlers = Object.assign({}, defaultHandlers, { '#editor': function() { return true; } }; // missing closing parenthesis