What is table in HTML?
In HTML, a Table is a structure used to organize the data in a two-dimensional grid of rows and columns.
It specifically designed for presenting tabular data like schedules, price list, or statistics, in a way that is easy to read and compare.
It can show text, images, links, and other elements inside the table.
Sample code:
What is border collapse?
The border-collapse property in CSS determine whether table cells share a single common border or maintain separate individual borders.
It is primarily applied for table elements or elements styled with display: table;.
Key property:
collapse: Adjacent table cells merge their borders into a single shared line. This removes any space between cells and is commonly used to create a "clean" grid look.
separate: Each cell keeps its own distinct border, resulting in "double" borders where cells meet. In this mode, you can use the border-spacing property to adjust the distance between those borders.

Top comments (0)