Skip to content

Instantly share code, notes, and snippets.

View vkatti's full-sized avatar

Vishal Katti vkatti

View GitHub Profile
@asbates
asbates / reactable-stacked-bar-chart.R
Created May 12, 2022 16:45
Create a stacked bar chart in a reactable cell with css flexbox
library(reactable)
library(htmltools)
# https://thomaswilburn.github.io/viz-book/css-flex.html
# was crucual to figuring this out. thanks Thomas!
bar_chart <-
function(value,
color_left = "#78c2ad",
color_right = "#f3969a",