So... for my job I am making a software solution that helps our employees have a centralized location to do their work on since we'll be transitioning to a Microsoft 365/Azure environment. My co-workers and I decided to use Vue.js as a way to control the view of the applications whereas Node.js is handling the backend.
The things we do:
- Single-Signon via MSAL (this is already working)
- Dynamic Module loading (this also works, we're able to upload, update, remove backend functionality without having to restart the server)
What we're looking for:
- Since we use MSAL for SSO and this code need to run on any page of the software package we've opted for an SPA as there is always the same code that needs to be ran regardless of what URI you are on, this way we have a 'main page' and the individual applications load in through Vue-router
- A way to dynamically create the Vue-router depending on the list of applications we add.
The issue:
And now that I've given some information, we finally get to the part where I ask the question.
Due to constraints put on us from the higher-ups we are only getting 1 port available to us (port 443), this meant that (by what we could find online) that Vue-cli is pretty much out of the question since we have our own backend code that needs to run as well. This means our own backend server needs to serve the vue page(s), therefore losing some functionality we get from Vue-cli.
That being said, we made Vue-router work by using the CDN library in our testing, but this comes with the issue that we can't access the data from the parent, which is something we need to be able to access since we need to be able to use the upper layer code for our requests to get data.
So for the actual question:
- Is there a way use Vue-cli AND your own backend code on the same Node process?
- If not, how can we use Vue-router and Vue-components and access parent data without having to use Vue-cli to build our application for us?
On both these questions we've failed to find any results by looking it up for ourselves, nor have we've been able to make this work by creating our own code (we're all fairly new to Vue, so we don't know the ins and outs yet).
I hope someone here can help us out on either of those 2 questions.
dist. everything thats inside you upload to your server. its 1index.htmlwith somejsandcssfolders