An Interest In:
Web News this Week
- April 2, 2024
- April 1, 2024
- March 31, 2024
- March 30, 2024
- March 29, 2024
- March 28, 2024
- March 27, 2024
September 28, 2022 07:22 am GMT
Original Link: https://dev.to/urstrulyvishwak/css-visibilityhidden-vs-displaynone-3p9c
CSS: visibility:hidden vs display:none
Frequently asked interview question.
display:none
- Won't allocate space on the page.visibility:hidden
- allocates space on the page.
-> Both aren't visible on the page
-> Both are visible in trackable in via DOM.
See below images for more clarification:
Thanks.
Please add your any further thoughts via comments.
Original Link: https://dev.to/urstrulyvishwak/css-visibilityhidden-vs-displaynone-3p9c
Share this article:
Tweet
View Full Article
Dev To
An online community for sharing and discovering great ideas, having debates, and making friendsMore About this Source Visit Dev To