arena-js
arena-js copied to clipboard
Docs example for block creation references string, but seems to require obj
Just a heads up for the readme example, noticed that attempts to create a block using arena.block().create("great-websites", "are.na/")
yielded a
.../node_modules/are.na/index.js:128
if (opts.content.match(/^https?:\/\//)) {
^
TypeError: Cannot read property 'match' of undefined
error. This appears to be addressed by passing an object rather than a string as the argument:
const newBlock = {
content: "are.na",
title: "Your Title",
description: "Your desc"
}
arena.block().create("great-websites", newBlock);