Ember addon for Cloudinary without jquery. Works good for fastboot.
ember install ember-cli-cloudinary-light
Add your cloud name to config/environment.js ENV:
cloudinary: {cloudName: 'some_cloud_name',},This component will render an built from a cloudinary url and options.
{{cloudinary-image'imageId'(hashwidth=100)}}Width and height attributes are set on the img tag as well as passed to cloudinary, allowing you to specify the resolution via the "dpr" attribute.
{{cloudinary-image'imageId'(hashwidth=100height=100dpr="2.0")}}This helper can be used in styles when you want to have dynamic url:s to cloudinary. It will return "background-image: url(..)" ready to use in a style element.
<divclass="your_class"style={{safe-cloudinary-url'image_id'width='auto'dpr='auto'}}></div>This component will render <source></source> tags generated from a cloudinary video and options.
<video>{{cloudinary-video'videoId'(hashwidth=100)}}</video>This component issues an API call to Cloudinary's Client-side resource lists and will make all Cloudinary resource items available under an items property.
Usage example:
{{#cloudinary-resource-list'my-cloudinary-tag'as|resourceList|}}{{#each resourceList.itemsas|item|}}{{cloudinary-imageitem.public_id(hashwidth=100)}}{{/each}}{{/cloudinary-resource-list}}Optional: the list will be sorted by an order metadata property on the Cloudinary resource.
Please see the Cloudinary API docs for all available properties of a resource item.
git clone <repository-url>this repositorycd ember-cli-cloudinary-lightnpm install
ember serve- Visit your app at http://localhost:4200.
npm run lint:jsnpm run lint:js -- --fix
ember test– Runs the test suite on the current Ember versionember test --server– Runs the test suite in "watch mode"ember try:each– Runs the test suite against multiple Ember versions
ember build
For more information on using ember-cli, visit https://ember-cli.com/.