The Cloudinary Vue SDK allows you to quickly and easily integrate your application with Cloudinary. Effortlessly optimize and transform your cloud's assets.
This Readme provides basic installation and usage information. For the complete documentation, see the Vue SDK Guide.
SDK Version | Vue 2 | Vue 3 |
---|---|---|
1.0.0 - 1.2.3 | V | X |
- After you create your application with Vue-CLI, navigate to the created app folder, and install Cloudinary SDK by:
vue add cloudinary
- Set up your cloud name and pick the components to use (or use all đ)
- A
cloudinary.js
file will be added to your src directory, at the same level as yourmain.js
file. Feel free to customize it if you like. And have fun with Cloudinary! đ¤ - For more information on the plugin, check out our Vue-CLI plugin for Cloudinary Repo.
npm install cloudinary-vue
yarn add cloudinary-vue
For Nuxt.js projects, use Cloudinary module. You can set it up by using the following:
yarn add @nuxtjs/cloudinary
# Or
npm i @nuxtjs/cloudinary
import Vue from 'vue';
import Cloudinary, { CldImage, CldVideo, CldTransformation, CldContext } from "cloudinary-vue";
Vue.use(Cloudinary, {
configuration: { cloudName: "demo" },
components: {
CldContext,
CldImage,
CldVideo,
CldTransformation,
}
});
You can also import the Cloudinary components manually in each of your components.
-
// Apply a single transformation <cld-context cloudName="demo"> <cld-image publicId="sample"> <cld-transformation crop="scale" width="200" angle="10" /> </cld-image> </cld-context>
// Chain (compose) multiple transformations <cld-context cloudName="demo"> <cld-image cloudName="demo" publicId="sample"> <cld-transformation angle="-45" /> <cld-transformation effect="trim" angle="45" crop="scale" width="600" /> <cld-transformation overlay="text:Arial_100:Hello" /> </cld-image> </cld-context>
- Use <cld-image> to generate image tags
- Use <cld-video> to generate video Tags
This SDK does not provide file upload functionality, however there are several methods of uploading from the client side.
If you run into an issue or have a question, you can either:
- Open a Github issue (for issues related to the SDK)
- Open a support ticket (for issues related to your account)
Cloudinary is a powerful media API for websites and mobile apps alike, Cloudinary enables developers to efficiently manage, transform, optimize, and deliver images and videos through multiple CDNs. Ultimately, viewers enjoy responsive and personalized visual-media experiencesâirrespective of the viewing device.
- Cloudinary Transformation and REST API References: Comprehensive references, including syntax and examples for all SDKs.
- MediaJams.dev: Bite-size use-case tutorials written by and for Cloudinary Developers
- DevJams: Cloudinary developer podcasts on YouTube.
- Cloudinary Academy: Free self-paced courses, instructor-led virtual courses, and on-site courses.
- Code Explorers and Feature Demos: A one-stop shop for all code explorers, Postman collections, and feature demos found in the docs.
- Cloudinary Roadmap: Your chance to follow, vote, or suggest what Cloudinary should develop next.
- Cloudinary Facebook Community: Learn from and offer help to other Cloudinary developers.
- Cloudinary Account Registration: Free Cloudinary account registration.
- Cloudinary Website
Released under the MIT license.