JSPM

snarl-welcome

0.1.1
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 1
  • Score
    100M100P100Q13246F
  • License MIT

Plugin for snarl that presents some information to new users.

Package Exports

  • snarl-welcome

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (snarl-welcome) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

snarl-welcome

Plugin for snarl that presents some information to new users.

Installation

To install the Welcome plugin, simply execute the following in your bot's primary folder:

npm install snarl-welcome

Finally, add the following values to config/index.json:

{
  "name": "snarl",
  "plugins": ["welcome"], // add the "welcome" plugin here
  "store": "data/store",
  "slack": {
    "token": "xoxb-1337-some-token"
  },
  "welcome": "Hello there, {{user}}!  Welcome to the community.", // modify to suit your needs
  "debug": false
}

If you'd like, you can even include an array of messages:

{
  "name": "snarl",
  "plugins": ["welcome"], // add the "welcome" plugin here
  "store": "data/store",
  "slack": {
    "token": "xoxb-1337-some-token"
  },
  "welcome": [
    "Hey there, {{user}}!",
    "Welcome to the community."
  ],
  "debug": false
}

Configuration

The Welcome plugin supports a special syntax for linking users and channels. Simply use the following structure in your message:

{{channel:SOME_CHANNEL_NAME}}

That's all there is to it. Enjoy!