0

in my case I want to add the 'div1' class to the 'div2' class but I don't really know how to do it. I tested a code but after the else part, the code doesn't execute (just the append method not other function like alert()...), is there any syntax error for the Magento logic

this is error in console :

require.js:166 Uncaught Error: Mismatched anonymous define() module: function($){
 "use strict";
 return function myfunctionCheck()
 {
 //code
 }
 else {
 //code
 }
 }
}
asked Dec 23, 2020 at 12:47
8
  • the error seems unrelated with your custom jquery code Commented Dec 23, 2020 at 13:09
  • what happens if you remove your custom jquery code? will the error also gone? Commented Dec 23, 2020 at 13:10
  • all of them ? or juste the append line Commented Dec 23, 2020 at 13:30
  • yeah all the custom codes Commented Dec 23, 2020 at 13:46
  • the same error when i refresh the page Commented Dec 23, 2020 at 13:50

1 Answer 1

1

Try this into your code part and you can increase and decrease time

setTimeout(function() {
 $(".div1").insertAfter($(".div2"));
}, 3000);
answered Dec 28, 2020 at 4:11

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.