What is CSS column-count property?
In column-count property specifies the number of columns when defining a multi-column layout.
Syntax
column-count: number|auto|initial|inherit;
Property values
-
number: It specifies the number of columns in which we want to divide our data. -
auto: This is the default value. It determines the number of columns by using other properties likecolumn-width. -
initial: This sets the value to its default value. -
inherit: This is used to inherit property from its parent value.
Code
The following is the basic column-count property:
Explanation
Here in this example, we have divided the paragraph into two columns. We can also split the section into multiple columns depending upon the need.