Bring HTML element to top (cascading)
Web Development
1
Posts
1
Posters
0
Views
1
Watching
-
Hello! I'm trying to bring DOM element (
div
) withposition: absolute
to front of others elements with same positioning. All elements are placed in the same container withposition: relative
. So I'm trying to reach similar behavior as desktop windows have when they are cascading. I know about these approaches: 1. Usingz-index
. Manually increment it and manage what is the highest. 2. Removing element from DOM container and appending it back to the end. Please, advice any other approaches or what from these ones is the best (especially from UX and performance point of view). Thanks!savbace