Skip to content
This repository was archived by the owner on Jul 7, 2026. It is now read-only.
This repository was archived by the owner on Jul 7, 2026. It is now read-only.

Rxjs Errors with Angular 6x #6

Description

@jderus

Since I liked it so much in Angular 4-5, I was attempting to use this package (v1.1.0) with Angular 6x (core: ^6.0.3, cli: ~6.0.8, rxjs: ^6.0.0). I got the following:

ERROR in ./node_modules/angular-logger2/node_modules/@angular/core/esm5/core.js
Module not found: Error: Can't resolve 'rxjs/Observable' in 'E:\MyProject\node_modules\angular-logger2\node_modules\@angular\core\esm5'
ERROR in ./node_modules/angular-logger2/node_modules/@angular/core/esm5/core.js
Module not found: Error: Can't resolve 'rxjs/Subject' in 'E:\MyProject\node_modules\angular-logger2\node_modules\@angular\core\esm5'
ERROR in ./node_modules/angular-logger2/node_modules/@angular/core/esm5/core.js
Module not found: Error: Can't resolve 'rxjs/Subscription' in 'E:\MyProject\node_modules\angular-logger2\node_modules\@angular\core\esm5'
ERROR in ./node_modules/angular-logger2/node_modules/@angular/core/esm5/core.js
Module not found: Error: Can't resolve 'rxjs/observable/merge' in 'E:\MyProject\node_modules\angular-logger2\node_modules\@angular\core\esm5'
ERROR in ./node_modules/angular-logger2/node_modules/@angular/core/esm5/core.js
Module not found: Error: Can't resolve 'rxjs/operator/share' in 'E:\MyProject\node_modules\angular-logger2\node_modules\@angular\core\esm5'

Here is what I saw in my package-lock.json file:

    "angular-logger2": {
      "version": "1.1.0",
      "resolved": "https://registry.npmjs.org/angular-logger2/-/angular-logger2-1.1.0.tgz",
      "integrity": "sha512-LqYkkEuNDQC0hVTxYkOGhPdRZaq9YDGIEzzpyDYPWUeKO1wu62O/xAHzO+UfFAxW78XQVDrjLFdu9SOs5UkFzQ==",
      "requires": {
        "@angular/core": "5.2.11",
        "moment": "2.22.2",
        "sprintf-js": "1.1.1"
      },

That didn't seem to match the 6.0.3 core in the repo package.json.

To me, this looked like breaking changes in rxjs as of 6x, so I quickly hacked the imports in node_modules to see if it would mitigate. That got everything to build, but then I encountered: #5

WARNING in ./node_modules/angular-logger2/node_modules/@angular/core/esm5/core.js
6570:15-36 Critical dependency: the request of a dependency is an expression

This seems to be related to this zombie thread here:
webpack/webpack#196

Should we be expecting 1.1.0 to work with Angular 6 out of the box?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions