A way to use any desired Node.js Library in Backend Bubble (Lifehack)

Hello! To the entire Bubble community

I’m sharing what I’ve been working on. I had a problem that I can’t use the desired Node.js bibliotoken in the server side of Bubble. Although there is a plugin to run Node.js (Toolbox). But the problem is that there is no way to corrupt the libraries. And if you make a separate plugin and connect the library there, the library is not visible in the Server Script action (Toolbox).

Today sat down at the computer to solve this problem and find a way around it all the same.

Instructions.

You need to copy the functionality of running Node js in the Toolbox plugin. And create your own separate plugin to run Node js.


After we have copied it, we need to connect libraries to this function.


Then go to the server side of bubble and find your action and run it and that’s it :slight_smile:
image

Thanks to those who appreciated my work :slight_smile:

This way you can connect any number of libraries and write code on Backend Bubble rather than in the plugin itself.

Used library on the example

7 Likes

This is over my head but thanks for it all the same, I’ve bookmarked it for future use.

I came across this while searching for the answer to a way more basic question and I’m hoping you can tell me. If there’s a html element running javascript that references a bunch of node modules, do you need to be making plugins for each module or can you just have them all in one?

Thanks again for the hack and sorry if this is word salad I’m completely ignorant about coding and just trying to grope through cloning basic games from github inside bubble

Thanks! Got close to needing to do that many times but always gave up - this time I have to figure it out. This sounds great.

very very cool

will give this a go

Thanks! this is amazing :muscle: really appreciate you sharing this

It’s super simple and finally have this working

I noticed some libraries work though and some don’t. Wonder the reason for this?

Out of interest, why did you have to declare “chance” as a new variable for it to work?

Thanks