Multiple start scripts

I’m making a discord bot and everything is fine and dandy. I’m now trying to make it start “node wafy.js” and node “server.js” so I can have a webpage running on the domain at the same time. The issue is I can’t figure out how to do that.

I tried “scripts”: {“start”: “node server.js && node wafy.js”},
and “scripts”: {
“start”: “node wafy.js”,
“start”: “node server.js”},

I can’t find a way to host my discord bot and a simple webpage in 1 project…

In your server.js at the bottom you can put the following line of code and it’ll start your bot:

require("./wafy.js");

Then in your start field you just need node server.js

2 Likes