import { Layout } from 'react-grid'
const { Grid, Row, Col } = Layout({
// set defaults for grid component
// so you don't have to specific columns,
// units breakpoints each time you use it
});
const breakpoints = {
sm: 576,
md: 768,
lg: 992,
xl: 1200
};
const gutters = 20;
const units = {
type: "px",
ratio: 1
};
const Box = () => (
<div
style={{
background: "#000",
marginBottom: "20px",
width: "100%",
minHeight: "30px"
}}
/>
);
export const BasicExample: React.SFC<{}> = () => {
return (
<Grid
columns={12}
units={units}
breakpoints={breakpoints}
gutters={gutters}
>
<Row>
<Col span={6}>
<Box />
</Col>
<Col span={6}>
<Box />
</Col>
</Row>
</Grid>
);
};
This repository has been archived by the owner on Jan 27, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
melbourne2991/react-grid
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
About
No description, website, or topics provided.
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published