Dependent Package Not Found


From I run:

var assertThrows = require("@kingjs/assert-throws")

Which unexpectedly fails with “Error: Cannot find module ‘@kingjs/assert’”

@kingjs/packages depends on:

  • @kingjs/assert and
  • @kingjs/assert-throws

@kingjs/assert-throws requires but does not include it in it’s list of dependencies:

  • @kingjs/assert

I figured when @kingjs/assert-throws tried to load @kingjs/assert it would succeed because @kingjs/packages depended on it. But didn’t work…


Unfortunately I’m unable to replicate the behavior you saw because @kingjs/packages has a reference error immediately after the requires resolve:

- Randy