JSFiddle - React, Tailwind, and code Playground
by Pysis
JavaScript
var dojoConfig = {
async: true,
baseUrl: '.'
};
require(["dojo/aspect"], function(aspect) {
var tempy = {
func: function() {
console.log("called");
},
bigfunc: function() {
var handle = aspect.before(this,"func", function () {
handle.remove();
console.log("before");
});
this.func();
}
};
tempy.bigfunc();
tempy.bigfunc();
})();
//expect 4 messages to be called
//Actual: 3 messages, missing 2nd "before" message