Skip to content
This repository was archived by the owner on May 1, 2025. It is now read-only.
This repository was archived by the owner on May 1, 2025. It is now read-only.

The wrong rxjs peerDependency for >=8 version #1059

@petro-konopelko

Description

@petro-konopelko

Is this a regression?

No

Description

The latest 8.0.1 version has rxjs peerDependency as *

{
  "name": "@datorama/akita",
  "version": "8.0.1",
  "description": "A Reactive State Management Tailored-Made for JS Applications",
  "keywords": [
    "angular",
    "state management",
    "react",
    "vue",
    "typescript",
    "javascript",
    "rxjs",
    "angular store",
    "store",
    "observable data stores",
    "redux",
    "reactive"
  ],
  "homepage": "https://github.com/datorama/akita/tree/master/libs/akita#readme",
  "bugs": {
    "url": "https://github.com/datorama/akita/issues"
  },
  "repository": {
    "type": "git",
    "url": "https://github.com/datorama/akita",
    "directory": "libs/akita"
  },
  "license": "Apache-2.0",
  "author": "Netanel Basal",
  "peerDependencies": {
    "rxjs": "*",
    "tslib": "2.4.1"
  },
  "main": "./src/index.js",
  "types": "./src/index.d.ts",
  "dependencies": {}
}

However in the 8.0.0 commit there was a re-writing of importing rxjs operators, the operators are imported from 'rxjs' rather then 'rxjs/operators'.
Such operators import(from rxjs) are actual since ^7.2.0.
So I guess, the rxjs peerDependency should update to ^7.2.0 or so.

Currently if we use rxjs@6.6.7 with @datorama/akita@8.0.1 it fails on build with error

./node_modules/@datorama/akita/src/lib/persistState.js:112:102-105 - Error: export 'map' (imported as 'map') was not found in 'rxjs' (possible exports: ArgumentOutOfRangeError, AsyncSubject, BehaviorSubject, ConnectableObservable, EMPTY, EmptyError, GroupedObservable, NEVER, Notification, NotificationKind, ObjectUnsubscribedError, Observable, ReplaySubject, Scheduler, Subject, Subscriber, Subscription, TimeoutError, UnsubscriptionError, VirtualAction, VirtualTimeScheduler, animationFrame, animationFrameScheduler, asap, asapScheduler, async, asyncScheduler, bindCallback, bindNodeCallback, combineLatest, concat, config, defer, empty, forkJoin, from, fromEvent, fromEventPattern, generate, identity, iif, interval, isObservable, merge, never, noop, observable, of, onErrorResumeNext, pairs, partition, pipe, queue, queueScheduler, race, range, scheduled, throwError, timer, using, zip)

Please provide a link to a minimal reproduction of the bug

No response

Please provide the exception or error you saw

./node_modules/@datorama/akita/src/lib/persistState.js:112:102-105 - Error: export 'map' (imported as 'map') was not found in 'rxjs' (possible exports: ArgumentOutOfRangeError, AsyncSubject, BehaviorSubject, ConnectableObservable, EMPTY, EmptyError, GroupedObservable, NEVER, Notification, NotificationKind, ObjectUnsubscribedError, Observable, ReplaySubject, Scheduler, Subject, Subscriber, Subscription, TimeoutError, UnsubscriptionError, VirtualAction, VirtualTimeScheduler, animationFrame, animationFrameScheduler, asap, asapScheduler, async, asyncScheduler, bindCallback, bindNodeCallback, combineLatest, concat, config, defer, empty, forkJoin, from, fromEvent, fromEventPattern, generate, identity, iif, interval, isObservable, merge, never, noop, observable, of, onErrorResumeNext, pairs, partition, pipe, queue, queueScheduler, race, range, scheduled, throwError, timer, using, zip)

Please provide the environment you discovered this bug in

rxjs@6.6.7
@datorama/akita@8.0.1

Anything else?

No response

Do you want to create a pull request?

No

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions