i have a nodejs expressjs app which uses slack, jsforce, and a internal api to perform…
- User
i have a nodejs expressjs app which uses slack, jsforce, and a internal api to perform some processes and syncing. I need to add a couple of pages which must use the same port 80 along with the api - i can have an api endpoint that provides some data which needs to be presented to the user. I would like to use vuejs, but i'm currently running pug which i'll still want to keep. what's the best way to do this
Assistant
There are a few ways to add a couple of pages to your existing Node.js ExpressJS app while still using the same port 80 and keeping your current pug setup:
Use a Separate Server for the New Pages: You can set up a separate server to handle the new pages, and have it communicate with your main app using AJAX or WebSockets. This way, you can use a different technology for the new pages, such as Vue.js, while still using ExpressJS for the rest of the app. To do this, you can use a library like socket.io to handle the real-time communication between the two servers.
Use a Single Server with Multiple Apps: Another option is to use a single server with multiple apps, each running in its own process. You can use ExpressJS to handle the API endpoints and the pug pages, and then use a separate framework like Vue.js to build the new pages. To do this, you can use a library like nest.js to create multiple apps within a single server process.
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.