Installing Svelte Cloudinary
To install Svelte Cloudinary, you can use your favorite package manager including npm, pnpm or yarn:
npm install svelte-cloudinary
Next, you need to setup the environment variable. Insert the following variable into your
PUBLIC_CLOUDINARY_CLOUD_NAME="[Your Cloud Name]"
Using Svelte Cloudinary
Check out our comprehensive guides on how to use the Svelte Cloudinary library. Whether you’re rendering images, generating social media cards, or looking to leverage our built-in upload UI, we’ve got you covered:
- CldImage: Optimize and transform images including dynamic cropping and resizing and background removal.
- CldOgImage: Create and add dynamically generated, custom Social Media cards to your site.
- CldUploadButton: Drop in a button that allows your visitors to upload files.
- CldUploadWidget: Gain full control of how you build your UI for uploading files.
- CldVideoPlayer: Add videos with optimization and transformations using the Cloudinary Video Player.
Or use the helper methods to generate URLs: