Answer the question
In order to leave comments, you need to log in
Execute a callback after changing the style attribute via JS on an element?
There is a block, through JS style.display is changed to 'block'. After changing the display property, you need to call the function.
Answer the question
In order to leave comments, you need to log in
Create a .htaccess file (this is how the file should look like, i.e. without a name, just an extension), in the root of the site and write AddDefaultCharset UTF-8 into it
<meta charset="utf-8">
should be
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
So what's the problem?
You wrap style.display in a function and call callback() in it
function elementShow(callback){
style.display
callback()
}
elementShow(() => {
//та самая callback функция
})
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question