Skip to main content

React YouTube Playlist v2 Release

· 2 min read

React YouTube Playlist version 2 is out! 🥳

Let's discuss the highlights.

Breaking Changes

This release comes with one breaking change.

  • Replace default import with named import. This change provides better compatibility with Node and Babel-like tools.

Other Changes

  • Replace EmotionJS dependency with inline styling.
  • Convert all configuration files to TypeScript.
  • Change the loading spinner's color to improve its contrast on dark and light background schemes.

How to Update the React YouTube Playlist Package

Here are the steps required to upgrade to the latest version:

Step 1: Install the latest version

>_ Terminal
npm install @codesweetly/react-youtube-playlist@latest

Alternatively, you can use Yarn or pnpm like so:

Yarn Installation
yarn upgrade @codesweetly/react-youtube-playlist --latest
PNPM Installation
pnpm update @codesweetly/react-youtube-playlist --latest

Step 2: Update the package's import syntax

Replace the package's default import statement with the named import syntax like so:

- import YouTubePlaylist from "@codesweetly/react-youtube-playlist";
+ import { YouTubePlaylist } from "@codesweetly/react-youtube-playlist";

How to Use the React YouTube Playlist Package

See the complete project-based guide to learn how to add the YouTubePlaylist package to your React applications. You can use the library with Vite, NextJS, Remix, or any other React app.

Your support matters: Buy me a coffee to support CodeSweetly's mission of simplifying coding concepts.

Join CodeSweetly Newsletter