Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ng: Can't bind to 'lazyLoad' since it isn't a known property of 'img' #251

Closed
MonchiLin opened this issue Dec 9, 2017 · 3 comments
Closed

Comments

@MonchiLin
Copy link

MonchiLin commented Dec 9, 2017




last pic:http://wx1.sinaimg.cn/mw690/9b5fc159ly1fmahepbh5vj20er0asmxs.jpg

i use ng version:5

@sapierens
Copy link
Collaborator

It's enough to only add LazyLoadImageModule under imports, no need to specify LazyLoadImageDirective under declarations.

Are you using SSR? If so, then make sure to include LazyLoadImageModule under imports in your shared app.module. Or if you don't have a shared one, then include it in both, client and server app.modules.

It's working fine for me on Angular 5.1.0

@MonchiLin
Copy link
Author

MonchiLin commented Dec 9, 2017

I tried to import LazyLoadImageModule results in shared.module and found that the problem was solved.
Sorry, I use Google Translate.
thank yooooooooooou!!
@sapierens

@tjoskar
Copy link
Owner

tjoskar commented Dec 16, 2017

Glad your problem was salved @muxi2015

Thanks, @sapierens!

@tjoskar tjoskar closed this as completed Dec 16, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants