Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@gr2m
Copy link
Contributor

@gr2m gr2m commented Dec 17, 2020

fixes #1447

@gr2m gr2m requested a review from a team as a code owner December 17, 2020 18:44
@gr2m gr2m merged commit 3356845 into master Dec 17, 2020
@gr2m gr2m deleted the 1447/import-transpiled-esmodule-function branch December 17, 2020 23:04
@github-actions
Copy link

🎉 This PR is included in version 11.0.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

ZauberNerd added a commit to ZauberNerd/probot that referenced this pull request Jan 14, 2021
There had been a fix previously probot#1448, to load transpiled app functions
for `probot run`.
This commit replaces the custom check for `.default` and `.__esModule`
properties with a dynamic import, which TypeScript compiles to a
`require` call that is capable of handling both, commonJS and ESM, as
long as `esModuleInterop` is set to `true` in probot's root
`tsconfig.json`.
Since a dynamic import is async, I had to wrap the `probot receive` CLI
in an async function.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

TypeError: appFn is not a function message when running the probot run command

2 participants