sample-botfuel-module v1.1.2
sample-botfuel-module
This package illustrates how to extend Botfuel-Dialog with a package.
Documentation draft
A Botfuel module has the same structure as the sdk and bots: folders adapters
, brains
, dialogs
, nlus
, views
. Intents, static content and templates are out of scope for the moment.
The file index.js
of the module exports a member botfuelModuleRoot
that points to that file tree (eg src
or build
).
Botfuel modules must be listed in the package.json
of the bot using it as project dependencies.
The bot config has a member modules
that lists the package names that will be taken into account at resolution time.
Botfuel components are resolved in the following order:
- bot components
- module components, in the order of appearance in
config.modules
- sdk components
Module code exposed by botfuelModuleRoot
is required by Botfuel Dialog. It can rely on babel presets latest
and stage-2
(details here)
Tests
See the package test-modules.