Comments (6)
I added the secure
prop and it works. Thanks!
<Video
secure
...
from cloudinary-react.
@skube this weird, since the protocol for serving images from Cloudinary relies on the window.location.protocol
, see https://github.com/cloudinary/cloudinary_js/blob/a50f25d3bb308c98549308667836fe165f9ff383/src/configuration.coffee#L15.
You can force the SDK to use HTTPS by providing the secure
attribute, e.g.:
<CloudinaryContext cloudName="demo" secure>
<Image publicId="nice_couple" width="300" crop="scale" />
</CloudinaryContext>
See full example here - https://codepen.io/eitanp461/pen/pOZwJe.
You can copy the HTML from the pen to a local server and see how the secure attribute affects the image delivery URL.
You can find a complete list of supported configuration parameters here - https://cloudinary.com/documentation/solution_overview#configuration_parameters
from cloudinary-react.
The problem for us is that we do SSR which does not have access to window.location.protocol
. So when it is rehydrated in the client not only is it mixed content but the app HTML does not match what React renders causing issues. The solution is manually setting the secure
option.
from cloudinary-react.
Hello, we noticed the same issue just today with v1.1.0.
from cloudinary-react.
@ronnyhaase did you try the solution above?
from cloudinary-react.
Yes I did, @strausr and it works.
But I think it would be nice if that wouldn't be necessary and to have a look at the actual reason.
from cloudinary-react.
Related Issues (20)
- accessing images in subfolders (uploadPreset) HOT 2
- cloudinary-react/samples/photo_album/ does not work HOT 4
- data- and aria- attributes are passed both correct and incorrectly cause a react-dom error HOT 3
- Multiple dependencies no-longer supported HOT 2
- TypeScript Declarations HOT 4
- sourceTypes incorrectly adding video as mimetype when using codec HOT 3
- Issue with versioning URL and On-Demand Download from S3 Bucket HOT 4
- Allow private requests for publicly allowed transformations HOT 1
- Image gallery? HOT 1
- Does the Placeholder component still work? HOT 7
- Images in chrome are not displayed when fetchFormat="auto" HOT 4
- how to use cloudinary with ant designs upload component? HOT 1
- Is Cloudinary-react doesn't support for typescript HOT 1
- TypeError: cld.videoPlayer is not a function HOT 1
- Support for token based authentication? HOT 3
- Getting tags with images HOT 4
- Url encoded characters in public ID not handled well in AdvancedImage component HOT 4
- React 18 release? HOT 2
- In typescript in react app HOT 3
- AdvancedVideo componet issue in Chrome Browser on mobile web
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cloudinary-react.