Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-grata

Package Overview
Dependencies
Maintainers
1
Versions
10
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-grata

Light weight react grid layout component that supports IE 11. What you draw is what you get.

  • 1.0.9
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
4
increased by100%
Maintainers
1
Weekly downloads
 
Created
Source

react-grata

Light weight react grid layout component that support IE 11. What you draw is what you get.

NPM JavaScript Style Guide

Goals

  • Provide a simplified API to use CSS Grid.
  • Support IE 11 with the same API.
  • Decouple layout away from the component trees.
  • Enable dynamic layout generation.

Demo

Demos

Install

npm install --save react-grata

Usage

import React from 'react'

import { Grid, Cell } from 'react-grata'

const App = () => {
  const matrix = [
    [1, 1, 1],
    [2, 3, 3],
    [2, 5, 6],
    [7, 7, 6],
    [8, 8, 8],
  ];
  const rowGap = "10px"
  const columnGap = "24px"

  return (
    <Grid rowGap={rowGap} columnGap={columnGap} matrix={matrix}>
      <Cell id={1}>Component One</Cell>
      <Cell id={2}>Component Two</Cell>
      <Cell id={3}>Component Three</Cell>
      <Cell id={5}>Component Five</Cell>
      <Cell id={6}>Component Six</Cell>
      <Cell id={7}>Component Seven</Cell>
      <Cell id={8}>Component Eight</Cell>
    </Grid>
  )
}

More Usages

API Reference

License

MIT © zhenyanghua

Keywords

FAQs

Package last updated on 28 May 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc