diff --git a/docs/embedded-iframe.html b/docs/embedded-iframe.html
new file mode 100644
index 00000000..0dbaa641
--- /dev/null
+++ b/docs/embedded-iframe.html
@@ -0,0 +1,80 @@
+
+
+
+
+ Cloudinary Video Player
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
Cloudinary Video Player
+
Embedded (iframe) player
+
+
+
+
+ Full documentation
+
+
+
Example Code:
+
+
+ <iframe
+ src="https://player.cloudinary.com/embed/?public_id=race_road_car&cloud_name=demo"
+ width="640"
+ height="360"
+ style="height: auto; width: 100%; aspect-ratio: 640 / 360;"
+ allow="autoplay; fullscreen; encrypted-media; picture-in-picture"
+ allowfullscreen
+ frameborder="0"
+ ></iframe>
+
+
+
+
+
+
diff --git a/docs/es-modules/netlify.toml b/docs/es-modules/netlify.toml
new file mode 100644
index 00000000..3738db3f
--- /dev/null
+++ b/docs/es-modules/netlify.toml
@@ -0,0 +1,2 @@
+[build]
+ ignore = "false"
diff --git a/docs/index.html b/docs/index.html
index 93134c15..a3c8961d 100644
--- a/docs/index.html
+++ b/docs/index.html
@@ -81,6 +81,9 @@ Some code examples:
UI Config
VAST & VPAID Support
VR/360 Videos
+
+ Embedded (iframe) player
+ ESM Imports
diff --git a/src/index.js b/src/index.js
index b3504ab0..629b66cb 100644
--- a/src/index.js
+++ b/src/index.js
@@ -26,11 +26,25 @@ export const videoPlayer = getVideoPlayer();
export const videoPlayers = getVideoPlayers();
export const videoPlayerWithProfile = getVideoPlayerWithProfile();
+const cloudinaryVideoPlayerLegacyConfig = config => {
+ console.warn(
+ 'Cloudinary.new() is deprecated and will be removed. Please use cloudinary.videoPlayer() instead.'
+ );
+ return {
+ videoPlayer: getVideoPlayer(config),
+ videoPlayers: getVideoPlayers(config)
+ };
+};
+
const cloudinary = {
...(window.cloudinary || {}),
videoPlayer,
videoPlayers,
- videoPlayerWithProfile
+ videoPlayerWithProfile,
+ Cloudinary: {
+ // Backwards compatibility with SDK v1
+ new: cloudinaryVideoPlayerLegacyConfig
+ }
};
window.cloudinary = cloudinary;