L
L
lavezzi12018-02-19 06:40:29
css
lavezzi1, 2018-02-19 06:40:29

How to animate the appearance of an element?

Hello. How to animate an element inserted into the DOM? I'm trying to do it by analogy as here - https://github.com/twbs/bootstrap/blob/v4-dev/js/s...
It seems that there is no special magic, there is no setTimeout() either. But there the animation works out.
https://jsfiddle.net/p9f7cteL/7/

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
Stalker_RED, 2018-02-19
@lavezzi1

It uses Util.reflow
The option with setTimeout 0 works fine https://jsfiddle.net/jjr9zpt4/
But you can do it without the timeout https://jsfiddle.net/jjr9zpt4/1/

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question