botpress / v12

Botpress OSS – v12
https://v12.botpress.com
GNU Affero General Public License v3.0
68 stars 83 forks source link

Feature request: running user defined code from an action for 11.x version #667

Closed Dimich-x33 closed 4 years ago

Dimich-x33 commented 5 years ago

Hello Botpress team,

I was inspired by this idea and found it very useful not only for me. But I want to have it as simple as possible - without heavy editors like monaco, but the final conclusion is up to you. Here are few things I imagine important to implement to run user-defined JS code inside one of builtin actions:

I already have almost completed implementation. Please, concider to include this functionality into botpress. Let me contribute and create PR after positive conlusion.

Regards, Dima

rndlaine commented 5 years ago

Hi @Dimich-x33, we're glad you're making this feature request because it's scheduled on our roadmap. However, we had some base requirements for it. One of them being Monaco. We're planning on converting actions to TS so typings support is very useful in this case.

How difficult would it be to convert your code to use Monaco? Let us know what you think!

Dimich-x33 commented 5 years ago

@rndlaine I've already integrated the monaco-editor(of course with syntax highlight and intellisence for javascript) into action-property-editor. Current user flow is:

All of these things above are already implemented. But currently without support for typescript.

Dimich-x33 commented 5 years ago

Will fork the repo tomorrow to show the changes

Dimich-x33 commented 5 years ago

@rndlaine I've pushed my changes into forked botpress repo here. Please take a look a them!

rndlaine commented 5 years ago

Awesome @Dimich-x33 we're gonna take a look at it thanks!

stale[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.