Components: how should i use <cdk-virtual-scroll-viewport> from @angular/cdk/scrolling

Created on 14 Aug 2018  路  3Comments  路  Source: angular/components

Bug, feature request, or proposal:

Error: Template parse errors:
Property binding cdkVirtualForOf not used by any directive on an embedded template. Make sure that the property name is spelled correctly and all directives are listed in the "@NgModule.declarations". ("

[ERROR ->]<div *cdkVirtualFor="let item of items">{{item}}</div>

What is the expected behavior?

What is the current behavior?

What are the steps to reproduce?

Providing a StackBlitz reproduction is the best way to share your issue.

StackBlitz starter: https://goo.gl/wwnhMV

What is the use-case or motivation for changing an existing behavior?

Which versions of Angular, Material, OS, TypeScript, browsers are affected?

Is there anything else we should know?

All 3 comments

I imported
import {ViewportRuler,ScrollDispatcher} from '@angular/cdk/scrolling'; in my component and also
import {ScrollDispatchModule ,ScrollDispatcher} from '@angular/cdk/scrolling';
import { VIEWPORT_RULER_PROVIDER } from '@angular/cdk/scrolling'; in my app.module.ts

Please keep GitHub issues for bug reports / feature requests. Better avenues for troubleshooting / questions are stack overflow, gitter, mailing list, etc.

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

_This action has been performed automatically by a bot._

Was this page helpful?
0 / 5 - 0 ratings

Related issues

MurhafSousli picture MurhafSousli  路  3Comments

3mp3ri0r picture 3mp3ri0r  路  3Comments

michaelb-01 picture michaelb-01  路  3Comments

LoganDupont picture LoganDupont  路  3Comments

crutchcorn picture crutchcorn  路  3Comments