mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-11-23 18:17:20 +00:00
Slight optimisation of $tw.utils.addClass()
This commit is contained in:
parent
9cff8eb741
commit
a65cfe98d5
@ -36,8 +36,8 @@ exports.addClass = function(el,className) {
|
||||
var c = el.className.split(" ");
|
||||
if(c.indexOf(className) === -1) {
|
||||
c.push(className);
|
||||
el.className = c.join(" ");
|
||||
}
|
||||
el.className = c.join(" ");
|
||||
};
|
||||
|
||||
exports.removeClass = function(el,className) {
|
||||
|
Loading…
Reference in New Issue
Block a user