Skip to content

block-kit-builder 0.0.12

Install from the command line:
Learn more about npm packages
$ npm install @springrole/block-kit-builder@0.0.12
Install via package.json:
"@springrole/block-kit-builder": "0.0.12"

About this version

@springrole/block-kit-builder

Getting started

This is a simple package that can be used to create the blocks and views required to interact with users on any Slack surface. This is based on Slack's own Block Kit Builder.

Installation

 npm install --save @springrole/block-kit-builder

Usage

const BlockKitBuilder = require("@springrole/block-kit-builder");

const blocks = BlockKitBuilder.Blocks.markdown({
  text: "Hello world!",
  blockId: "hello_block",
  ...BlockKitBuilder.Accessory.button({
    text: "Click me!",
    style: "primary",
    actionId: "click",
    value: "something",
  }),
});

// OR

const { Blocks, Accessory } = require("@springrole/block-kit-builder");
const blocks = Blocks.markdown({
  text: "Hello world!",
  blockId: "hello_block",
  ...Accessory.button({
    text: "Click me!",
    style: "primary",
    actionId: "click",
    value: "something",
  }),
});

License

@springrole/block-kit-builder is licensed under the MIT License.

Details


Assets

  • block-kit-builder-0.0.12-npm.tgz

Download activity

  • Total downloads 59
  • Last 30 days 0
  • Last week 0
  • Today 0