+ 1
What does <div> tag do?
2 Respuestas
+ 1
The div element is a block-level element, meaning it will have a line break at the start and end of it. It contains text and other elements
0
On its own, div doesn't do much, it is invisible. It can serve as container for other elements, to hold together contents that belong together logically (semantically) or visually, for example to contain a menu bar on your page.
Its other common usage is styling and animation with css, as with stylesheets you can turn div's into graphical elements of various shapes, colors and sizes and move and transform them.