scullyio / scully

The Static Site Generator for Angular apps
https://scully.io/
MIT License
2.56k stars 257 forks source link

Angular 17 Detected Routes but not rendering them. #1677

Open jasonc624 opened 6 months ago

jasonc624 commented 6 months ago

🐞 Bug report

Description

This code use to work but somewhere along the line whilst upgrading to 17 it stopped working. All components in the "landing" project have been converted to modules from standalone components.

🔬 Minimal Reproduction

npx scully --project landing --host='0.0.0.0' --scanRoutes --no-warning --showGuessError --showBrowser=false --pluginsError=false --logSeverity=normal

💻Your Environment

Node 20

Angular Version: ^17.0.8


    "@angular/cdk": "^17.0.4",
    "@angular/common": "^17.0.8",
    "@angular/compiler": "^17.0.8",
    "@angular/core": "^17.0.8",
    "@angular/fire": "17.0.0",

Scully Version: ^2.1.41 & 2.1.42


    "@scullyio/init": "^2.1.41",
    "@scullyio/ng-lib": "^2.1.41",
    "@scullyio/platform-server": "^2.1.41",
    "@scullyio/scully": "^2.1.41",
    "@scullyio/scully-plugin-puppeteer": "^2.1.0",

Scully Config scully.landing.config.ts



export const config: ScullyConfig = {
  puppeteerLaunchOptions: {
    args: [
      "--disable-gpu",
      "--renderer",
      "--no-sandbox",
      "--no-service-autorun",
      "--no-experiments",
      "--no-default-browser-check",
      "--disable-dev-shm-usage",
      "--disable-setuid-sandbox",
      "--no-first-run",
      "--no-zygote",
      "--single-process",
      "--disable-extensions",
      "--user-agent='Scully Navigator'",
      "--disable-headless-warning",
    ],
    headless: true,
  },
  projectRoot: "./projects/landing/src",
  projectName: "landing",
  distFolder: "./dist/landing", // output directory of your Angular build artifacts
  outDir: "./dist/static", // directory for scully build artifacts
  defaultPostRenderers: postRenderers,
  routes: {
    "/v/:id": {
      type: "json",
      id: {
        url: vanityUrl,
        property: "id",
      },
    },
  },
};

Discovery Happens

Screenshot 2024-05-01 at 6 29 18 PM

Rendering does not

Screenshot 2024-05-01 at 6 30 50 PM

jasonc624 commented 6 months ago

Is there any alternatives to scully?

KaliaHayes commented 5 months ago

Is there any alternatives to scully?

Fortunately, there is! I would recommend checking out Analog, the Angular meta-framework. It’s new, extremely well maintained, and constantly being improved.

The developer experience is fantastic, as well.

Hope it fits your needs.