I want to add /static/ in front of all the paths in index.html. Since Flask looks for static files inside the /root_folder/static folder. Even though I have placed all the files inside the static folder, it is unable to get the files as the path in the index.html file is not correct.
My current directory structure in Flask looks like this
web_ui
src
-static
-web_app.py
logs
config
This is what the path to various files in index.html looks like.
<script src="assets/js/apexcharts.min.js"></script>
<script src="assets/js/bootstrap.bundle.min.js"></script>
I would like to have
<script src="/static/assets/js/apexcharts.min.js"></script>
<script src="/static/assets/js/bootstrap.bundle.min.js"></script>
is there any way to change the angular.json file? I have changed the output directory
"architect": {
"build": {
"builder": "@angular-devkit/build-angular:browser",
"options": {
"outputPath": "../web_ui/src/static/", #<----
"index": "src/index.html",
"main": "src/main.ts",
"polyfills": "src/polyfills.ts",
"tsConfig": "tsconfig.app.json",
"assets": [
"src/favicon.ico",
"src/assets"
],
"styles": [
"src/custom-theme.scss",
"src/styles.css"
],
"scripts": [
"src/assets/js/main.js",
"node_modules/apexcharts/dist/apexcharts.min.js"
]
I have looked into this answer but the person has not explained how to do it. Do I have to manually change the path?