![Create React App Officially Deprecated Amid React 19 Compatibility Issues](https://cdn.sanity.io/images/cgdhsj6q/production/04fa08cf844d798abc0e1a6391c129363cc7e2ab-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Create React App Officially Deprecated Amid React 19 Compatibility Issues
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
hls-stream-creator
Advanced tools
Create an M3U8 playlist from media file using FFMPEG.
npm i hls-stream-creator
This package using fluent-ffmpeg so ffmpeg must be installed it requires at least ffmpeg 0.9 to work.
You must also have ffprobe installed (it comes with ffmpeg in most distributions).
Windows users: most probably ffmpeg and ffprobe will not be in your %PATH
, so you must set %FFMPEG_PATH
and %FFPROBE_PATH
.
Debian/Ubuntu users: the official repositories have the ffmpeg/ffprobe executable in the libav-tools
package, and they are actually rebranded avconv/avprobe executables (avconv is a fork of ffmpeg). They should be mostly compatible, but should you encounter any issue, you may want to use the real ffmpeg instead. You can either compile it from source or find a pre-built .deb package at https://ffmpeg.org/download.html (For Ubuntu, the ppa:mc3man/trusty-media
PPA provides recent builds).
const hlsStreamCreator = require('hls-stream-creator');
(async () => {
const settings = {
renditions: [
{
resolution: {
width: 1920,
height: 1080,
},
bitrate: 8000,
audioRate: 320,
},
{
resolution: {
width: 1280,
height: 720,
},
bitrate: 4000,
audioRate: 192,
},
],
printLogs: true
};
try {
await hlsStreamCreator('./sample.mkv', './output', settings);
} catch (err) {
console.log(`Oops we got an error, err: ${err}`);
}
})();
Returns a Promise<void>
.
Type: string
Media file.
If media file does not exists will be thrown an error.
Type: string
Destination directory which will hold all the mpeg-ts files with m3u8 files.
Type: object
In addition, you can specify the below options.
Type:
{
resolution: {
width: number, // example: 1920
height: number, // example: 1080
},
bitrate: number, // example: 8000
audioRate: number, // example: 320
}
Default: []
Must be at least one rendition if not will be thrown an error.
Type: Speed | string
Default: veryfast
The speed will be for making the stream files.
Can be: 'ultrafast' || 'superfast' || 'veryfast' || 'faster' || 'fast' || 'medium' || 'slow' || 'slower' || 'veryslow'
Type: string
Default: libx264
Recommended not to change this value because the default value libx264 is supported in all browsers.
Type: string
Default: aac
Recommended not to change this value because the default value aac is supported in all browsers.
Type: boolean
Default: true
In case we want to see the process logs of ffmpeg.
FAQs
Create an M3U8 playlist from media file using FFMPEG
The npm package hls-stream-creator receives a total of 1 weekly downloads. As such, hls-stream-creator popularity was classified as not popular.
We found that hls-stream-creator demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.