scully: cli: dist/static does not include assets if Angular project is output to dist/

🐞 Bug report

Description

In dist/static, I have the following

  • index.html
  • assets
    • scully-routes.json

My webmanifest.manifest, favicon.ico, sitemap.xml, robots.txt, etc aren’t available on my static site. It seems like all of this stuff is configured in the angular.json and part of my build in dist/, so it seems like Scully should copy that over for the static site? Or is there some other step or approach that I’m missing?

πŸ”¬ Minimal Reproduction

  1. Generate a new app with the CLI
  2. Follow the Scully docs
  3. Check to see if your favicon.ico loads on your static site and that it’s in dist/static/favicon.ico

πŸ’»Your Environment

Angular Version:


Angular CLI: 9.0.0-rc.6
Node: 12.13.0
OS: darwin x64

Angular: 9.0.0-rc.6
... animations, cli, common, compiler, compiler-cli, core, forms
... language-service, platform-browser, platform-browser-dynamic
... router, service-worker
Ivy Workspace: Yes

Package                           Version
-----------------------------------------------------------
@angular-devkit/architect         0.900.0-rc.6
@angular-devkit/build-angular     0.900.0-rc.6
@angular-devkit/build-optimizer   0.900.0-rc.6
@angular-devkit/build-webpack     0.900.0-rc.6
@angular-devkit/core              9.0.0-rc.6
@angular-devkit/schematics        9.0.0-rc.6
@angular/cdk                      9.0.0-rc.5
@angular/fire                     5.2.3
@angular/material                 9.0.0-rc.5
@ngtools/webpack                  9.0.0-rc.6
@schematics/angular               9.0.0-rc.6
@schematics/update                0.900.0-rc.6
rxjs                              6.5.3
typescript                        3.6.4
webpack                           4.41.2

Scully Version:


    "@scullyio/init": "0.0.8",
    "@scullyio/ng-lib": "latest",
    "@scullyio/scully": "latest",

πŸ”₯ Exception or Error


GET http://localhost:5000/firebase-performance-es2015.js net::ERR_ABORTED 404 (Not Found)
(index):2790 GET http://localhost:5000/runtime-es2015.js net::ERR_ABORTED 404 (Not Found)
4(index):2790 GET http://localhost:5000/polyfills-es2015.js net::ERR_ABORTED 404 (Not Found)
16(index):2762 GET http://localhost:5000/assets/DevIntentLogo.png 404 (Not Found)
(index):2790 GET http://localhost:5000/assets/material-design-icons/MaterialIcons-Regular.woff2 net::ERR_ABORTED 404 (Not Found)
(index):2792 GET http://localhost:5000/assets/material-design-icons/MaterialIcons-Regular.woff net::ERR_ABORTED 404 (Not Found)
(index):1 GET http://localhost:5000/assets/material-design-icons/MaterialIcons-Regular.ttf net::ERR_ABORTED 404 (Not Found)
manifest.webmanifest:1 GET http://localhost:5000/manifest.webmanifest 404 (Not Found)
manifest.webmanifest:1 Manifest: Line: 1, column: 1, Syntax error.
favicon.ico:1 GET http://localhost:5000/favicon.ico 404 (Not Found)
favicon-32x32.png:1 GET http://localhost:5000/assets/favicon-32x32.png 404 (Not Found)
favicon-16x16.png:1 GET http://localhost:5000/assets/favicon-16x16.png 404 (Not Found)

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 17 (16 by maintainers)

Commits related to this issue

Most upvoted comments

OK, I changed my project to output to dist/web instead of dist/ in angular.json and I now get the πŸ˜„ new Angular build imported and my assets are all properly copied.

OK, I changed my project to output to dist/web instead of dist/ in angular.json and I now get the πŸ˜„ new Angular build imported and my assets are all properly copied.

I also have the same issue and this workaround worked.

Yes, it is already doing that. But somehow it’s not always pulling in all assets, while it pull sin the rest of the app. Looking into that

Op vr 20 dec. 2019 om 17:02 schreef Michael Prentice < notifications@github.com>:

@SanderElias https://github.com/SanderElias Scully should be able to check the build->options->outputPath field in angular.json in order to find out where the application is output during the build.

β€” You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/scullyio/scully/issues/56?email_source=notifications&email_token=AAJQ6OYKX2ZMSY57BREEMATQZTUADA5CNFSM4J452EY2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEHNJ4DI#issuecomment-567975437, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJQ6O2NPFYPEYYNNGRVCJDQZTUADANCNFSM4J452EYQ .

@Splaktar thanks for found the issue! … @SanderElias can you check this?