Skip to content

Instantly share code, notes, and snippets.

@dangdennis
Created December 1, 2018 03:48
Show Gist options
  • Save dangdennis/a8f6a1e504c45fa8264a671f6083c5e4 to your computer and use it in GitHub Desktop.
Save dangdennis/a8f6a1e504c45fa8264a671f6083c5e4 to your computer and use it in GitHub Desktop.
/*
1. Use stylesheets
BuckleScript provides escape hatches.
You can run native Javascript code with [%bs.raw {| CODE GOES BETWEEN HERE |}]
*/
[%bs.raw {|require('./index.css')|}];
/* 2. Use inline styles */
let styles = ReactDOMRe.Style.make(~backgroundColor="peach", ~width="500px", ());
<div style=styles />;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment