Skip to content

An utility component for pushing other elements and avoid `padding`, `margin` for the web

Notifications You must be signed in to change notification settings

DCKT/spacer-web

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Spacer

An utility component for pushing other elements and avoid padding, margin everywhere.

Usage

Install :

$ yarn add @dck/spacer-web

Web

import Spacer from "@dck/spacer-web"

const App = () => {
  return (
    <div>
      <h1>Hello</h1>
      <Spacer height={10} />
      <p>world</p>
    </div>
  )
}

ReasonML

Add the module to your bsconfig.json file :

{
  "bs-dependencies": ["@dck/spacer-web"]
}

Use it in your app code :

[@react.component]
let make = () => {  
  <div>
    <h1>{"Hello" |> React.string}</h1>
    <Spacer height=10 />
    <p>{"World" |> React.string}</p>
  </div>
};

About

An utility component for pushing other elements and avoid `padding`, `margin` for the web

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages