-
Notifications
You must be signed in to change notification settings - Fork 8
2. Frontpage
By default when running docker-compose up -d from the root of the project, front-end is served on port 80.
In the browser, just type in: http://localhost/
and "tada", you will be served a nice IMTDb front-end.
in ./frontend/config there are a few '.env' files, where for example the url of the proxy-api can be changed. var: ROOT_PROXY_API
when you want to have port '80' changed to a different port, this can be done in the docker-compose.yml
file in the root of your project, by changing te ports of the 'frontend' service.
Currently development of frontend is not setup in docker, because it gave some complications. I will change that in the near future.
However, if you want to roll up your sleeves and get your hands dirty on the frontend. here is how to.
Install a latest version of npm (Node Package Manager) on your system. https://nodejs.org/en/.
Navigate to the frontend folder:
cd v1/frontend
Install the dependencies, by executing:
npm i
Run the development mode by:
npm run dev
Now a 'serve and watch' mode is setup, you can change the code in the frontend sub folder src
, and changes are recognized and updated immediately.
The website will be served on the development url: http://localhost:8090
by default.
This projects makes use of Vue.js, which is great and neat front-end framework. info can be found here: https://vuejs.org/
This project makes use of webpack, and some nice quality checks like eslint and stylint.
during development you will be informed in the console when something needs to be optimized.
When done don't forget to make a final build for deployment. This is done by executing:
npm run build
To test it locally, docker needs to rebuild its containers, this can be easily done by executing this commands:
docker-compose build && docker-compose up -d
check: