OR ranges (^1.0.0 || ^2.0.0)

^1.0.0 || ^2.0.0 means at least 1.0.0 and below 2.0.0, or at least 2.0.0 and below 3.0.0.

Meaning and matches

Examples

Note

Libraries use || to support two major versions of a peer dependency at once, such as React 17 and 18.

Other range forms