I replaced this piece of code and get rid of this dependency
#Pick a top palette from colourlovers
url <- "http://www.colourlovers.com/api/palettes/top&format=json"
out <- rjson::fromJSON(readLines(url)[1], simplify = TRUE)
palette <- data.table::rbindlist(out)
colors <- palette %>% filter(id == sample(palette$id,1)) %>% select(colors) %>% pull %>% paste0("#", .)
#palette <- sample(clpalettes('top'), 1)[[1]]
#colors <- palette %>% swatch %>% .[[1]]
I replaced this piece of code and get rid of this dependency
#Pick a top palette from colourlovers
url <- "http://www.colourlovers.com/api/palettes/top&format=json"
out <- rjson::fromJSON(readLines(url)[1], simplify = TRUE)
palette <- data.table::rbindlist(out)
colors <- palette %>% filter(id == sample(palette$id,1)) %>% select(colors) %>% pull %>% paste0("#", .)
#palette <- sample(clpalettes('top'), 1)[[1]]
#colors <- palette %>% swatch %>% .[[1]]