A temporary fix for v0.3.0.0 of SpringBot so that the client-side is served correctly
If you have mapped you local drive or directory into your virtual machine (SpringBot Development Environment: Source Code), then you will need to update a few files for your application client-side to be served correctly.
- Navigate to your projects
clientside
directory, enter:cd /data/local/[projectname]/clientside
- Edit the
angular.json
file:
sudo nano angular.json
- Within the JSON object, find the
projects > architect > build > options
section.
{
...
"projects": {
...
"architect": {
"build": {
"options": {
},
...
}
- At the end of the
options
section, add the following property:
"preserveSymlinks": true
- In the
styles
array, add these two lines:
"node_modules/@ng-select/ng-select/themes/default.theme.css",
"node_modules/ng-pick-datetime/assets/style/picker.min.css"
- The final
build
section should look like this:
"build": {
"builder": "@angular-devkit/build-angular:browser",
"options": {
"outputPath": "../serverside/src/main/resources/static",
"index": "src/index.html",
"main": "src/main.ts",
"polyfills": "src/polyfills.ts",
"tsConfig": "src/tsconfig.app.json",
"assets": [
"src/favicon.ico",
"src/assets"
],
"styles": [
"src/styles.scss",
"node_modules/@ng-select/ng-select/themes/default.theme.css",
"node_modules/ng-pick-datetime/assets/style/picker.min.css"
],
"scripts": [],
"es5BrowserSupport": true,
"preserveSymlinks": true
},
- Press
CTRL-X
thenY
to save and quit - Now edit
src/styles.scss
.
sudo nano src/styles.scss
- Comment out the two imports for the CSS we just put into the
angular.json
:
// @import "~@ng-select/ng-select/themes/default.theme.css";
// @import "~ng-pick-datetime/assets/style/picker.min.css";
- Press
CTRL-X
thenY
to save and quit
Your project should now be ready to serve up the client-side.