Closed joeyguerra closed 1 year ago
I like the idea of splitting it up into multiple PRs. async might be required for loading '.mjs' files as adapters. But Let me see what I can do.
It was too difficult for me to tease out the changes so I'm going to create separate PRs for each one and close this one, using it as reference. I'm already seeing some benefits in this approach. It forced me to hone an efficient development setup, come up with ideas on testing adapter integration, and add additional tests for adapter loading.
BREAKING CHANGE: Loading the adapter is done with async/await semantics. You can now specify an adapter with the .mjs file extension and Hubot will look in ./src/adapters for the file. In addition, scripts with the .mjs file extension can be used. They will be loaded with async/await symantics via the ES6
import
statement.