mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
This reverts commit 52c74d3b4a.
The reason for revert: breaking some apps in Google's codebase.
PR Close #50334
This commit is contained in:
@@ -686,7 +686,7 @@ function getComponentId(componentDef: ComponentDef<unknown>): string {
|
||||
// https://github.com/angular/components/blob/d9f82c8f95309e77a6d82fd574c65871e91354c2/src/material/core/option/option.ts#L248
|
||||
// https://github.com/angular/components/blob/285f46dc2b4c5b127d356cb7c4714b221f03ce50/src/material/legacy-core/option/option.ts#L32
|
||||
|
||||
const hashSelectors = JSON.stringify([
|
||||
const hashSelectors = [
|
||||
componentDef.selectors,
|
||||
componentDef.ngContentSelectors,
|
||||
componentDef.hostVars,
|
||||
@@ -696,16 +696,12 @@ function getComponentId(componentDef: ComponentDef<unknown>): string {
|
||||
componentDef.decls,
|
||||
componentDef.encapsulation,
|
||||
componentDef.standalone,
|
||||
componentDef.signals,
|
||||
componentDef.exportAs,
|
||||
componentDef.inputs,
|
||||
componentDef.outputs,
|
||||
// We cannot use 'componentDef.type.name' as the name of the symbol will change and will not
|
||||
// match in the server and browser bundles.
|
||||
Object.getOwnPropertyNames(componentDef.type.prototype),
|
||||
!!componentDef.contentQueries,
|
||||
!!componentDef.viewQuery,
|
||||
]);
|
||||
].join('|');
|
||||
|
||||
for (const char of hashSelectors) {
|
||||
hash = Math.imul(31, hash) + char.charCodeAt(0) << 0;
|
||||
|
||||
Reference in New Issue
Block a user