nestjs / ng-universal

Angular Universal module for Nest framework (node.js) 🌷
https://nestjs.com
MIT License
441 stars 68 forks source link

Unable to setup with angular 10 #375

Closed muhammad-usman-anwar closed 4 years ago

muhammad-usman-anwar commented 4 years ago

I'm submitting a...


[ ] Regression 
[x] Bug report
[ ] Feature request
[ ] Documentation issue or request
[ ] Support request => Please do not submit support request here, instead post your question on Stack Overflow.

Current behavior

Minimal reproduction of the problem with instructions

ALL testing was done after creating a new angular app using ng new, with both yarn | npm

Environment


Angular version: 10.0.0
Nest version: 6.11.11 (this is from lock file, set by the plugin is 6.0.0)


For Tooling issues:
- Node version: 12.18.1  
- Platform: Windows 10 Version 2004 | Also tested on WSL 2 
anvial commented 4 years ago

Hi,

Same problem...

Do you find any solutions?

muhammad-usman-anwar commented 4 years ago

@anvial Nothing worked I tried a lot of things, even tried to fix/copy the way how the angular's own universal package is setup

anvial commented 4 years ago

@anvial Nothing worked I tried a lot of things, even tried to fix/copy the way how the angular's own universal package is setup

You have the following error?

ERROR Endpoint unreachable!

ERROR Error: Uncaught (in promise): Endpoint unreachable!
...
rejection: 'Endpoint unreachable!',
  promise: ZoneAwarePromise [Promise] {
    __zone_symbol__state: 0,
    __zone_symbol__value: 'Endpoint unreachable!'
  },
  zone: Zone {
    _parent: Zone {
      _parent: null,
      _name: '<root>',
      _properties: {},
      _zoneDelegate: [ZoneDelegate]
    },
    _name: 'angular',
    _properties: { isAngularZone: true, maybeDelayChangeDetection: false },
    _zoneDelegate: ZoneDelegate {
      _taskCounts: [Object],
      zone: [Circular],
      _parentDelegate: [ZoneDelegate],
      _forkZS: null,
      _forkDlgt: null,
      _forkCurrZone: null,
      _interceptZS: null,
      _interceptDlgt: null,
      _interceptCurrZone: null,
      _invokeZS: [Object],
      _invokeDlgt: [ZoneDelegate],
      _invokeCurrZone: [Circular],
      _handleErrorZS: [Object],
      _handleErrorDlgt: [ZoneDelegate],
      _handleErrorCurrZone: [Circular],
      _scheduleTaskZS: [Object],
      _scheduleTaskDlgt: [ZoneDelegate],
      _scheduleTaskCurrZone: [Circular],
      _invokeTaskZS: [Object],
      _invokeTaskDlgt: [ZoneDelegate],
      _invokeTaskCurrZone: [Circular],
      _cancelTaskZS: [Object],
      _cancelTaskDlgt: [ZoneDelegate],
      _cancelTaskCurrZone: [Circular],
      _hasTaskZS: [Object],
      _hasTaskDlgt: [ZoneDelegate],
      _hasTaskDlgtOwner: [Circular],
      _hasTaskCurrZone: [Circular]
    }
  },
  task: ZoneTask {
    _zone: Zone {
      _parent: [Zone],
      _name: 'angular',
      _properties: [Object],
      _zoneDelegate: [ZoneDelegate]
    },
    runCount: 0,
    _zoneDelegates: null,
    _state: 'notScheduled',
    type: 'microTask',
    source: 'Promise.then',
    data: ZoneAwarePromise [Promise] {
      __zone_symbol__state: 0,
      __zone_symbol__value: 'Endpoint unreachable!'
    },
    scheduleFn: undefined,
    cancelFn: undefined,
    callback: [Function],
    invoke: [Function]
  }
anvial commented 4 years ago

It's pity, I'd like to integrate NestJs backend to my angular10 app. But downgrade angular to 9 is not the answer. Will be waiting for advises, or updates...

jamieking1996 commented 4 years ago

Is there any update on this? I've tried using with Angular 10 and it seems to be installing on old version of nestjs/ng-universal (version 2.0.1). I used this in another project with Angular 9 a couple of months ago and it all worked fine with version 3.2.0 of nestjs/ng-universal

thanks

kamilmysliwiec commented 4 years ago

Fixed in @nestjs/ng-universal@4.0.1. Please, make sure to install the latest version :)