René's URL Explorer Experiment


Title: DI - Handle the "InjectFlags" in Injector_.get() · Issue #31776 · angular/angular · GitHub

Open Graph Title: DI - Handle the "InjectFlags" in Injector_.get() · Issue #31776 · angular/angular

X Title: DI - Handle the "InjectFlags" in Injector_.get() · Issue #31776 · angular/angular

Description: 🚀 feature request Relevant Package This feature request is for @angular/core Description At the moment the Injector_.get() implementation doesn't handle the InjectFlags. I'd like the feature so that I can use the component Injector like ...

Open Graph Description: 🚀 feature request Relevant Package This feature request is for @angular/core Description At the moment the Injector_.get() implementation doesn't handle the InjectFlags. I'd like the feature so tha...

X Description: 🚀 feature request Relevant Package This feature request is for @angular/core Description At the moment the Injector_.get() implementation doesn't handle the InjectFlags. I'd like the featur...

Opengraph URL: https://github.com/angular/angular/issues/31776

X: @github

direct link

Domain: github.com


Hey, it has json ld scripts:
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"DI - Handle the \"InjectFlags\" in Injector_.get()","articleBody":"\u003c!--🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅\r\n\r\nOh hi there! 😄 \r\n\r\nTo expedite issue processing please search open and closed issues before submitting a new one.\r\nExisting issues often contain information about workarounds, resolution, or progress updates.\r\n\r\n🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅🔅-->\r\n\r\n\r\n# 🚀 feature request\r\n\r\n### Relevant Package\r\n\u003c!-- Can you pin-point one or more @angular/* packages the are relevant for this feature request? -->\r\n\u003c!-- ✍️edit: --> This feature request is for @angular/core\r\n\r\n\r\n### Description\r\nAt the moment the `Injector_.get()` implementation doesn't handle the `InjectFlags`. \r\n I'd like the feature so that I can use the component `Injector` like this:\r\n```typescript\r\n@Component(...)\r\nexport class SomeComponent {\r\n    // Here I get an instance of Injector_\r\n    constructor(injector: Injector) {\r\n        this.myService = injector.get(SomeService, null, InjectFlags.SkipSelf);\r\n    }\r\n}\r\n```\r\n\r\n\r\n\r\n### Describe the solution you'd like\r\nIt looks like you already handle the `DeepFlags`.   [refs.ts:342](https://github.com/angular/angular/blob/da2880d7c495022405102f89b8c641b23516388d/packages/core/src/view/refs.ts#L342)  \r\nYou probably just need to map and pass the `InjectFlags` to the `resolveDeep()` function\r\n```typescript\r\nclass Injector_ implements Injector {\r\n  ...\r\n  get(token: any, notFoundValue: any = Injector.THROW_IF_NOT_FOUND): any {\r\n    ...\r\n    return Services.resolveDep(\r\n        this.view, this.elDef, allowPrivateServices,\r\n        {flags: DepFlags.None, token, tokenKey: tokenKey(token)}, notFoundValue);\r\n  }\r\n}\r\n```\r\nI don't think I have enough knowledge of the project to submit a PR by myself, so I'm relying on you for this.  \r\nThanks in advance for your work\r\n","author":{"url":"https://github.com/TomMenga","@type":"Person","name":"TomMenga"},"datePublished":"2019-07-22T09:26:49Z","url":"https://github.com/angular/angular/issues/31776"}

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format)
route-controllervoltron_issues_fragments
route-actionissue_layout
fetch-noncev2:c4bb91bf-fc12-4d14-e11a-fbe7e437a2bd
current-catalog-service-hash81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114
request-idD8D2:4E3C:12AAC87:18BCEBD:6B011BCC
html-safe-noncedc2eba34b68f9f45e287092c0dc365d01e1a946252cb855e05c384c6ab2365c5
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEOEQyOjRFM0M6MTJBQUM4NzoxOEJDRUJEOjZCMDExQkNDIiwidmlzaXRvcl9pZCI6IjE0NDA3ODIzMzQ5Nzc3MTEwNTIiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ==
visitor-hmac65a2073d5e1361aac3848a83a6b4d95d59a093a62892ea1a0f1482b73a283523
hovercard-subject-tagissue:470988455
github-keyboard-shortcutsrepository,issues,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/issues_fragments/issue_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/angular/angular/31776/issue_layout
twitter:imagehttps://opengraph.githubassets.com/9871bfedcb4cf372023f88c01f62e89af8fd57a170b04b40f4cfc26fe3917262/angular/angular/issues/31776
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/9871bfedcb4cf372023f88c01f62e89af8fd57a170b04b40f4cfc26fe3917262/angular/angular/issues/31776
og:image:alt🚀 feature request Relevant Package This feature request is for @angular/core Description At the moment the Injector_.get() implementation doesn't handle the InjectFlags. I'd like the feature so tha...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernameTomMenga
hostnamegithub.com
expected-hostnamegithub.com
Nonecc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c
turbo-cache-controlno-preview
go-importgithub.com/angular/angular git https://github.com/angular/angular.git
octolytics-dimension-user_id139426
octolytics-dimension-user_loginangular
octolytics-dimension-repository_id24195339
octolytics-dimension-repository_nwoangular/angular
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id24195339
octolytics-dimension-repository_network_root_nwoangular/angular
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release8c77c9e8439031ad54c75a250694842892f693e1
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-nameissues

Links:

Skip to contenthttps://github.com/angular/angular/issues/31776#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fangular%2Fangular%2Fissues%2F31776
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fangular%2Fangular%2Fissues%2F31776
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fissues_fragments%2Fissue_layout&source=header-repo&source_repo=angular%2Fangular
Reloadhttps://github.com/angular/angular/issues/31776
Reloadhttps://github.com/angular/angular/issues/31776
Reloadhttps://github.com/angular/angular/issues/31776
angularhttps://github.com/angular
angularhttps://github.com/angular/angular
Codehttps://github.com/angular/angular
Issues835 (835)https://github.com/angular/angular/issues
Pull requests141 (141)https://github.com/angular/angular/pulls
Discussionshttps://github.com/angular/angular/discussions
Actionshttps://github.com/angular/angular/actions
Projectshttps://github.com/angular/angular/projects
Security and quality40 (40)https://github.com/angular/angular/security
Insightshttps://github.com/angular/angular/insights
https://github.com/angular/angular
New issuehttps://github.com/login?return_to=https://github.com/angular/angular/issues/31776
New issuehttps://github.com/login?return_to=https://github.com/angular/angular/issues/31776
DI - Handle the "InjectFlags" in Injector_.get()https://github.com/angular/angular/issues/31776#top
area: coreIssues related to the framework runtimehttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22area%3A%20core%22
core: dihttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22core%3A%20di%22
featureLabel used to distinguish feature request from other issueshttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22feature%22
state: has PRhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22state%3A%20has%20PR%22
Backloghttps://github.com/angular/angular/milestone/82
https://github.com/TomMenga
TomMengahttps://github.com/TomMenga
on Jul 22, 2019https://github.com/angular/angular/issues/31776#issue-470988455
refs.ts:342https://github.com/angular/angular/blob/da2880d7c495022405102f89b8c641b23516388d/packages/core/src/view/refs.ts#L342
Nexthttps://github.com/angular/angular/issues/31776?timeline_page=1
AndrewKushnirhttps://github.com/AndrewKushnir
area: coreIssues related to the framework runtimehttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22area%3A%20core%22
on Jul 22, 2019https://github.com/angular/angular/issues/31776#event-2501349823
ngbothttps://github.com/apps/ngbot
needsTriagehttps://github.com/angular/angular/milestone/83
on Jul 22, 2019https://github.com/angular/angular/issues/31776#event-2501349850
mheveryhttps://github.com/mhevery
featureLabel used to distinguish feature request from other issueshttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22feature%22
on Aug 20, 2019https://github.com/angular/angular/issues/31776#event-2571247343
ngbothttps://github.com/apps/ngbot
needsTriagehttps://github.com/angular/angular/milestone/83
Backloghttps://github.com/angular/angular/milestone/82
on Aug 20, 2019https://github.com/angular/angular/issues/31776#event-2571247376
https://github.com/pmilic021
pmilic021https://github.com/pmilic021
on Feb 23, 2020https://github.com/angular/angular/issues/31776#issuecomment-590070144
https://github.com/stupidawesome
stupidawesomehttps://github.com/stupidawesome
on Feb 25, 2020https://github.com/angular/angular/issues/31776#issuecomment-590882899
di.ts#L628https://github.com/angular/angular/blob/9.1.0-next.1/packages/core/src/render3/di.ts#L628
pkozlowski-opensourcehttps://github.com/pkozlowski-opensource
core: dihttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22core%3A%20di%22
on Mar 16, 2020https://github.com/angular/angular/issues/31776#event-3135292253
https://github.com/kpeterbauer
kpeterbauerhttps://github.com/kpeterbauer
on Jul 10, 2020https://github.com/angular/angular/issues/31776#issuecomment-656769272
https://angular.io/api/core/Injectorhttps://angular.io/api/core/Injector
https://github.com/dimamarksman
dimamarksmanhttps://github.com/dimamarksman
on Aug 19, 2020https://github.com/angular/angular/issues/31776#issuecomment-675920104
https://github.com/johncrim
johncrimhttps://github.com/johncrim
on Oct 27, 2020https://github.com/angular/angular/issues/31776#issuecomment-717398208
https://github.com/johncrim
johncrimhttps://github.com/johncrim
on Oct 27, 2020https://github.com/angular/angular/issues/31776#issuecomment-717407624
https://github.com/matthewjh
matthewjhhttps://github.com/matthewjh
on Dec 12, 2020https://github.com/angular/angular/issues/31776#issuecomment-743740012
https://github.com/johncrim
johncrimhttps://github.com/johncrim
on Dec 13, 2020https://github.com/angular/angular/issues/31776#issuecomment-744065389
https://github.com/johncrim
johncrimhttps://github.com/johncrim
on Dec 14, 2020https://github.com/angular/angular/issues/31776#issuecomment-744747820
JoostKhttps://github.com/JoostK
state: has PRhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22state%3A%20has%20PR%22
on May 13, 2021https://github.com/angular/angular/issues/31776#event-4744365812
angular-robothttps://github.com/apps/angular-robot
votes requiredhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22votes%20required%22
on Jun 4, 2021https://github.com/angular/angular/issues/31776#event-4843633868
https://github.com/apps/angular-robot
angular-robothttps://github.com/apps/angular-robot
on Jun 4, 2021https://github.com/angular/angular/issues/31776#issuecomment-854787540
documentationhttps://github.com/angular/angular/blob/e29eb8abfbfdfb793e08ac88e14b7ba6d2ff2136/docs/GITHUB_PROCESS.md#feature-request-process
https://github.com/apps/angular-robot
angular-robothttps://github.com/apps/angular-robot
on Jun 24, 2021https://github.com/angular/angular/issues/31776#issuecomment-867667808
communityhttps://angular.io/resources?category=community
packagehttps://angular.io/guide/creating-libraries
documentationhttps://github.com/angular/angular/blob/e29eb8abfbfdfb793e08ac88e14b7ba6d2ff2136/docs/GITHUB_PROCESS.md#feature-request-process
angular-robothttps://github.com/apps/angular-robot
insufficient voteshttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22insufficient%20votes%22
on Jun 24, 2021https://github.com/angular/angular/issues/31776#event-4934856070
alxhubhttps://github.com/alxhub
on Oct 28, 2021https://github.com/angular/angular/issues/31776#event-5535948045
fix(core): support `InjectFlags` argument in `NodeInjector.get()` (#4…https://github.com/angular/angular/commit/8f402c9d06f4e6f16759f73df44438f2ba725a30
#4…https://github.com/angular/angular/pull/41592
https://docs.github.com/articles/closing-issues-via-commit-messages
8f402c9https://github.com/angular/angular/commit/8f402c9d06f4e6f16759f73df44438f2ba725a30
fix(core): support `InjectFlags` argument in `NodeInjector.get()` (#4…https://github.com/angular/angular/commit/8ae99821d657ba940df998f6abec425f8a1f4cb1
#4…https://github.com/angular/angular/pull/41592
https://docs.github.com/articles/closing-issues-via-commit-messages
8ae9982https://github.com/angular/angular/commit/8ae99821d657ba940df998f6abec425f8a1f4cb1
alxhubhttps://github.com/alxhub
completedhttps://github.com/angular/angular/issues?q=is%3Aissue%20state%3Aclosed%20archived%3Afalse%20reason%3Acompleted
65cb2c5https://github.com/angular/angular/commit/65cb2c5565803e546d474cbc82b8014af3ff5430
on Oct 28, 2021https://github.com/angular/angular/issues/31776#event-5535948286
https://github.com/apps/angular-automatic-lock-bot
angular-automatic-lock-bothttps://github.com/apps/angular-automatic-lock-bot
on Nov 28, 2021https://github.com/angular/angular/issues/31776#issuecomment-981110029
automatic conversation locking policyhttps://github.com/angular/angular/blob/8f24bc9443b3872fe095d9f7f77b308a361a13b4/docs/GITHUB_PROCESS.md#conversation-locking
angular-automatic-lock-bothttps://github.com/apps/angular-automatic-lock-bot
on Nov 28, 2021https://github.com/angular/angular/issues/31776#event-5681303600
Serginhohttps://github.com/Serginho
on Jan 20, 2022https://github.com/angular/angular/issues/31776#event-5925980013
fix(core): support `InjectFlags` argument in `NodeInjector.get()` (an…https://github.com/TuLotero/angular/commit/fe5d55b2c0453cee222d59f5637087ca3d143ab5
an…https://github.com/angular/angular/pull/41592
https://docs.github.com/articles/closing-issues-via-commit-messages
fe5d55bhttps://github.com/TuLotero/angular/commit/fe5d55b2c0453cee222d59f5637087ca3d143ab5
Sign up for freehttps://github.com/signup?return_to=https://github.com/angular/angular/issues/31776
Sign in to commenthttps://github.com/login?return_to=https://github.com/angular/angular/issues/31776
area: coreIssues related to the framework runtimehttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22area%3A%20core%22
core: dihttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22core%3A%20di%22
featureLabel used to distinguish feature request from other issueshttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22feature%22
state: has PRhttps://github.com/angular/angular/issues?q=state%3Aopen%20label%3A%22state%3A%20has%20PR%22
BacklogNo due datehttps://github.com/angular/angular/milestone/82
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.