Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add strictCheck option #11

Merged
merged 3 commits into from
Jan 23, 2018
Merged

add strictCheck option #11

merged 3 commits into from
Jan 23, 2018

Conversation

UziTech
Copy link
Contributor

@UziTech UziTech commented Jun 2, 2017

This will allow registering from a submodule

var codependency = require('codependency');
var requirePeer = codependency.register(module, { strictCheck: false });

fixes #4
fixes #5

@ronkorving ronkorving self-assigned this Jun 4, 2017
@ronkorving
Copy link
Collaborator

Thank you for your contribution.

#4 should already be fixed iirc.
For #5, could @Raynos perhaps confirm if this would do the trick?

@@ -290,7 +290,7 @@ exports.register = function (baseModule, options) {

// find the nearest package.json

var pkg = exports.findPackage(baseModule, true);
var pkg = exports.findPackage(baseModule, options.strictCheck !== false);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add a mention of this option to both the JSDoc above, and the ReadMe?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@ronkorving ronkorving merged commit 1ef098f into Wizcorp:master Jan 23, 2018
@ronkorving
Copy link
Collaborator

Cheers 👍

@ronkorving
Copy link
Collaborator

And released under 2.1.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Cannot be used inside non-main module Does not support nested modules.
2 participants