What would be better for performance, having many hidden elements on a page, or creating them and destroying them as they are needed with javascript upon request. For exampl
IMHO you should do another kind of consideration, since is obvious that page load speed is affected by it's size in term of kb.
How to calculate web page size ?
what is the maximum size?
so, your problem is not properly the number of dom elements, you have a lot of things to do before care of hidden elements number! ;) hope this help
REFERENCE:
TOOLS