Title: createComponent function example not work on 16.2.1 · Issue #51492 · angular/angular · GitHub
Open Graph Title: createComponent function example not work on 16.2.1 · Issue #51492 · angular/angular
X Title: createComponent function example not work on 16.2.1 · Issue #51492 · angular/angular
Description: Which @angular/* package(s) are the source of the bug? core Is this a regression? Yes Description The document wrong: https://angular.io/api/core/createComponent const componentRef = [createComponent](https://angular.io/api/core/createCo...
Open Graph Description: Which @angular/* package(s) are the source of the bug? core Is this a regression? Yes Description The document wrong: https://angular.io/api/core/createComponent const componentRef = [createCompone...
X Description: Which @angular/* package(s) are the source of the bug? core Is this a regression? Yes Description The document wrong: https://angular.io/api/core/createComponent const componentRef = [createCompone...
Opengraph URL: https://github.com/angular/angular/issues/51492
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"createComponent function example not work on 16.2.1","articleBody":"### Which @angular/* package(s) are the source of the bug?\r\n\r\ncore\r\n\r\n### Is this a regression?\r\n\r\nYes\r\n\r\n### Description\r\n\r\nThe document wrong: https://angular.io/api/core/createComponent\r\n``` \r\nconst componentRef = [createComponent](https://angular.io/api/core/createComponent)(HelloComponent, {host, environmentInjector});\r\n\r\nhost was change to hostElement, should become this\r\nconst componentRef = [createComponent](https://angular.io/api/core/createComponent)(HelloComponent, {hostElement, environmentInjector});\r\n\r\n```\r\n\r\nBtw it just not work.\r\n\r\n### Please provide a link to a minimal reproduction of the bug\r\n\r\n[this one work]\r\nhttps://stackblitz.com/edit/angular-anxyrb?file=src%2Fmain.ts,src%2Findex.html \r\n[not work version]\r\nhttps://codesandbox.io/p/sandbox/relaxed-feather-27fv8y?file=/src/app/app.component.ts:63,6\r\n\r\n### Please provide the exception or error you saw\r\n\r\n```true\r\nNG0912: Component ID generation collision detected. Components 'HelloComponent' and 'HelloComponent' with selector 'hello-component' generated the same component ID. To fix this, you can change the selector of one of those components or add an extra host attribute to force a different ID. Find more at https://angular.io/errors/NG0912\r\n```\r\n\r\n\r\n### Please provide the environment you discovered this bug in (run `ng version`)\r\n\r\n_No response_\r\n\r\n### Anything else?\r\n\r\nng version result:\r\n\r\n\r\n","author":{"url":"https://github.com/hiepxanh","@type":"Person","name":"hiepxanh"},"datePublished":"2023-08-24T10:08:04Z","url":"https://github.com/angular/angular/issues/51492"}
| react-profiling | 0 |
| react-import-map | react,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-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:46ac365a-5c3d-4bcd-ba72-e8da81f5f31a |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 9E66:3DD488:166116B:1C61696:6B0137B6 |
| html-safe-nonce | ef347b936d728fa3df2a8e469468dabc9ab60da0b8dfc75656137506be71b64b |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5RTY2OjNERDQ4ODoxNjYxMTZCOjFDNjE2OTY6NkIwMTM3QjYiLCJ2aXNpdG9yX2lkIjoiODM0MjA4NjQzNTQ0MDcwMDcwIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 9815ee67780ac6a726786f4de62e0091ed4c3c7398c084390bd40bb4f4034200 |
| hovercard-subject-tag | issue:1864830288 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/angular/angular/51492/issue_layout |
| twitter:image | https://opengraph.githubassets.com/119667925238099e98a7128d950857f71c347a16f4469ac78caad15ae3cc4ecd/angular/angular/issues/51492 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/119667925238099e98a7128d950857f71c347a16f4469ac78caad15ae3cc4ecd/angular/angular/issues/51492 |
| og:image:alt | Which @angular/* package(s) are the source of the bug? core Is this a regression? Yes Description The document wrong: https://angular.io/api/core/createComponent const componentRef = [createCompone... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | hiepxanh |
| hostname | github.com |
| expected-hostname | github.com |
| None | cc5dfdd32f62ebd3223cab3af3aa2b268d3605218237326a48a99d1efd89495c |
| turbo-cache-control | no-preview |
| go-import | github.com/angular/angular git https://github.com/angular/angular.git |
| octolytics-dimension-user_id | 139426 |
| octolytics-dimension-user_login | angular |
| octolytics-dimension-repository_id | 24195339 |
| octolytics-dimension-repository_nwo | angular/angular |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 24195339 |
| octolytics-dimension-repository_network_root_nwo | angular/angular |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 8c77c9e8439031ad54c75a250694842892f693e1 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width