Angular Desarrollo web

Can’t bind to ‘items’ since it isn’t a known property of ‘virtual-scroller’

Tuve este error al realizar pruebas unitarias luego de implementar este componente.

1. If 'virtual-scroller' is an Angular component and it has 'items' input, then verify that it is part of this module.
2. If 'virtual-scroller' is a Web Component then add 'CUSTOM_ELEMENTS_SCHEMA' to the '@NgModule.schemas' of this component to suppress this message.
3. To allow any property add 'NO_ERRORS_SCHEMA' to the '@NgModule.schemas' of this component.

Para corregir este problema realice este cambio.

import { NO_ERRORS_SCHEMA } from "@angular/core";

y luego esto:

beforeEach(async(() => {
      declarations: [ yourcomponent ],
      schemas: [NO_ERRORS_SCHEMA]


Similar Posts

Leave a Reply

Your email address will not be published. Required fields are marked *

%d bloggers like this: