Your Web News in One Place

Help Webnuz

Referal links:

Sign up for GreenGeeks web hosting
October 15, 2021 03:11 pm GMT

A simple CSS Grid System

sc-css-grid-system

Simple CSS grid system component built with styled component for react.
sc-css-grid-system utilizes the power of CSS grid and styled-components to easily create responsive grids.

key features

  1. responsive breakpoint xs,sm,md,lg,xl
  2. responsive gutter/gap option
  3. really easy to use

Responsive Grid Example:

import {Grid} from 'sc-css-grid-system';function CssGridSystem() {    return (        <Grid xs={2} sm={3} md={4} lg={6} xl={12} gap={30}>            <div>1</div>            <div>2</div>            <div>3</div>            <div>4</div>            <div>5</div>            <div>6</div>            <div>7</div>            <div>8</div>            <div>9</div>            <div>10</div>            <div>11</div>            <div>12</div>        </Grid>    );}

render as:
Hnet-image (1)

for complete documentation and demo:

Github repo

NPM

SC-CSS-Grid-System


Original Link: https://dev.to/madeelahsan/a-simple-css-grid-system-5a5i

Share this article:    Share on Facebook
View Full Article

Dev To

An online community for sharing and discovering great ideas, having debates, and making friends

More About this Source Visit Dev To