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

bs-nice-components

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bs-nice-components

Library to that makes creating ReasonReact components with bs-nice really nice

  • 0.1.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
Maintainers
1
Weekly downloads
 
Created
Source

Nice Components

This is an attempt to bring the styled-components/glamorous style of component creation to reason. I do this by creating a wrapper around the bs-nice library.

module Title = (val NiceComponents.h1([|
 Color(White),
 TextAlign(Center),
 Raw("font-size", "1.5em")
|]));

module Wrapper = (val NiceComponents.section([|
  BackgroundColor(Hex("db4d3f")),
  Padding(Em(4.))
|]));

let component = ReasonReact.statelessComponent("HelloWorld");

let make = _children => {
  ...component,
  render: _self => <Wrapper> <Title> (ReasonReact.stringToElement("Hello World!")) </Title> </Wrapper>
};

Install

npm install --save bs-nice-components

State

This is currently very early days. Expect this library to very volatile as I make changes in the future.

Todo

  • Create a macro to generate the tag functions
  • Add a type safe way to pass parameters to components
  • make the whole world beautiful... and type-safe :P

Keywords

FAQs

Package last updated on 13 Feb 2018

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