analogjs / analog

The fullstack meta-framework for Angular. Powered by Vite and Nitro
https://analogjs.org
MIT License
2.57k stars 245 forks source link

Error when evaluating SSR module ~analog/entry-server: #350

Closed raulmar0 closed 1 year ago

raulmar0 commented 1 year ago

Please provide the environment you discovered this bug in.

Angular 15.2.6 node 16.19.1 create-analog 0.2.14 (variant angular-v15) Macbook Air M1 chip (2020)

Which area/package is the issue in?

create-analog

Description

When I follow the "get started" guide and try to run npm run dev everything runs correctly but when you try to open the url, you'll run into an error.

Please provide the exception or error you saw

6:32:31 PM [vite] Error when evaluating SSR module /node_modules/@angular/core/fesm2015/core.mjs: failed to import "rxjs"

6:32:31 PM [vite] Error when evaluating SSR module ~analog/entry-server:

node:internal/process/promises:279
            triggerUncaughtException(err, true /* fromPromise */);
            ^

TypeError: Method Promise.prototype.then called on incompatible receiver [object Object]
    at ZoneAwarePromise.then (<anonymous>)
    at node:internal/per_context/primordials:440:35
    at new Promise (<anonymous>)
    at new SafePromise (node:internal/per_context/primordials:408:29)
    at node:internal/per_context/primordials:440:9
    at Array.map (<anonymous>)
    at arrayToSafePromiseIterable (node:internal/per_context/primordials:437:5)
    at node:internal/per_context/primordials:453:21
    at new Promise (<anonymous>)
    at primordials.SafePromiseAll (node:internal/per_context/primordials:452:3)

Other information

No response

I would be willing to submit a PR to fix this issue

brandonroberts commented 1 year ago

Duplicate. Try node 16.17.0 or 18.13.0+. this bug has been fixed in Angular

https://github.com/analogjs/analog/issues/321#issuecomment-1498967194

raulmar0 commented 1 year ago

Thanks, it worked