new CloudinaryImageComponent()

Description

The Cloudinary image component.

Properties
Name Type Description
transformation CloudinaryImage

Generated by @cloudinary/url-gen

plugins Plugins

Advanced image component plugins accessibility(), responsive(), lazyload(), placeholder()

imageAttributes

Optional attributes include alt, width, height, loading

Methods


ngOnInit()

Description

On init creates a new HTMLLayer instance and initializes with ref to img element, user generated cloudinaryImage and the plugins to be used.


ngOnChanges()

Description

On update, we cancel running plugins and update the image instance with the state of user cloudinaryImage and the state of plugins.


ngOnDestroy()

Description

On destroy, we cancel the currently running plugins.


addAttributes()

Description

Add attributes to img element.