Skip to content

Cannot convert undefined or null to object if there are no dependencies #81

@nullnullend

Description

@nullnullend

I have a monorepository where some child package.json is missing dependencies.

{
  "name": "@project/client",
  "version": "1.0.9",
  "private": true,
  "scripts": {
    "start": "cross-env BROWSER=none PORT=3200 craco start",
    "build": "cross-env craco build",
  }
}

I get this error:

E:\project\node_modules\react-app-alias-ex\src\index.js:58
  const list = [].concat(...depsSections.map(s => Object.keys(pack[s])))

TypeError: Cannot convert undefined or null to object

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions