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

Ability to provide custom NgModuleRef #495

Merged
merged 5 commits into from
Jan 25, 2023
Merged

Conversation

msgoloborodov
Copy link
Contributor

No description provided.

Copy link
Owner

@gund gund left a comment

Choose a reason for hiding this comment

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

Thanks for the PR!

Could you please also add unit tests for this new options?
To test ngModuleRef you could provide something in that module and then try to inject that in the injected component's injector to see if it's available.
Same strategy could be used for environmentInjector option as well.

P.S. You can use Github Codespaces to make changes fully online in full VScode IDE and run build/tests there without having to install anything locally:
image

Copy link
Owner

@gund gund left a comment

Choose a reason for hiding this comment

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

Looks good!

Before merging I'd like to make a few small adjustments to match the types with Angular and also add the following text to the readme.md file as a documentation after this location:

**Since v10.6.0**: You can provide custom NgModuleRef (`[ndcDynamicNgModuleRef]`)
or EnvironmentInjector (`[ndcDynamicEnvironmentInjector]`) for your dynamic component.

Alternatively I can make those changes myself but you would have to allow maintainers to push to this PR (I've already made those changes locally on this PR but have no permissions to push them).

Copy link
Owner

@gund gund left a comment

Choose a reason for hiding this comment

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

Thanks for the fixes!
I've just updated imports all now looks good to go.

@gund gund merged commit bfaceb3 into gund:master Jan 25, 2023
@github-actions
Copy link

🎉 This PR is included in version 10.6.0 🎉

The release is available on:

Your semantic-release bot 📦🚀

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

Successfully merging this pull request may close these issues.

None yet

2 participants