
Security News
Package Maintainers Call for Improvements to GitHub’s New npm Security Plan
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.
will-it-play
Advanced tools
I was tired of having local home video files not play on my **Playstation 4**. Now at least I'll know that's the case before I get all the way to the console w/ a flash drive. This is also compatible with **Playstation 5**.
I was tired of having local home video files not play on my Playstation 4. Now at least I'll know that's the case before I get all the way to the console w/ a flash drive. This is also compatible with Playstation 5.
yarn global add will-it-play
or using your JS package manager of choice.
You must also have ffmpeg
available. Follow these instructions to download it and these to ensure the ffmpeg
binary is available at runtime.
This is best used as a CLI tool:
% will-it-play ~/Desktop/raindrops.mp4
raindrops.mp4: ✅
% will-it-play ~/Desktop/raindrops-bad-video.ogv
raindrops-bad-video.ogv: ❌
There's also detailed mode, which tells you why a video will or won't play:
% will-it-play ~/Desktop/raindrops-bad-video.ogv -d
raindrops-bad-video.ogv: ❌
┌───────────┬────────┬────────┐
│ Factor │ Value │ Valid? │
├───────────┼────────┼────────┤
│ video │ theora │ ⚠️ │
├───────────┼────────┼────────┤
│ audio │ vorbis │ ⚠️ │
├───────────┼────────┼────────┤
│ extension │ .ogv │ ❌ │
└───────────┴────────┴────────┘
It can also be used by its' JS/TS API:
import { willItPlay } from 'will-it-play'
willItPlay('~/Desktop/raindrops.mp4').then((result) => {
if (result.videoWillPlay) {
console.log('Yes!')
} else if (result.videoWillPlay === false) {
console.log('No.')
} else {
console.log('Maybe?')
}
// detailed info is found at `result.info`
})
See the CLI source for a more complete example of the code usage.
There are probably a lot of audio and video codecs you might have files in. If you see a lot of "⚠️" when using this tool and know for sure if the file does or doesn't play, kindly file an issue with that information.
Copyright-free test video provided by this entry on pexels.com.
1.0.1
released 2021-10-26
FAQs
I was tired of having local home video files not play on my **Playstation 4**. Now at least I'll know that's the case before I get all the way to the console w/ a flash drive. This is also compatible with **Playstation 5**.
The npm package will-it-play receives a total of 0 weekly downloads. As such, will-it-play popularity was classified as not popular.
We found that will-it-play 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
Maintainers back GitHub’s npm security overhaul but raise concerns about CI/CD workflows, enterprise support, and token management.
Product
Socket Firewall is a free tool that blocks malicious packages at install time, giving developers proactive protection against rising supply chain attacks.
Research
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.