Go to file
2019-03-25 06:31:49 -07:00
config Trailing commas! 2019-03-19 06:55:24 -07:00
css Improve behavior of text when panes are too small 2019-03-23 17:47:53 -07:00
demo Better initial layout when viewing library 2019-03-23 17:59:06 -07:00
docs Add note about when methods were added in usage.md 2019-03-25 06:19:44 -07:00
examples README tweaks 2019-03-19 08:36:59 -07:00
experiments Move skin extraction code from the skin museum into this package 2019-03-21 18:41:52 -07:00
js Don't autoplay on next when stoppedFixes #730 2019-03-25 06:31:49 -07:00
presets Add builtin presets json 2018-11-09 07:13:10 -08:00
scripts Trailing commas! 2019-03-19 06:55:24 -07:00
skins Add Internet Archive skin 2018-10-02 09:48:19 -07:00
.babelrc Remove redundent plugin declaration 2018-11-19 19:57:34 -08:00
.editorconfig Format css according to prettier default config 2018-10-20 10:12:19 -07:00
.eslintignore
.eslintrc In a world with types, consistent-return is less important 2019-03-19 07:52:06 -07:00
.gitattributes Typo 2019-01-16 13:54:43 -08:00
.gitignore Move demo site into its own directory 2018-12-29 16:06:51 -08:00
.prettierignore Upgrade Prettier 2019-01-24 20:52:53 -08:00
.travis.yml Remove disused build cruft (#742) 2019-03-06 23:55:46 -08:00
CHANGELOG.md Don't autoplay on next when stoppedFixes #730 2019-03-25 06:31:49 -07:00
index.d.ts Add more methods to Webamp 2019-03-24 21:51:52 -07:00
jest-puppeteer.config.js Trailing commas! 2019-03-19 06:55:24 -07:00
LICENSE.txt
netlify.toml Move demo site into its own directory 2018-12-29 16:06:51 -08:00
package.json Remove prop types 2019-03-22 16:37:58 -07:00
README.md Fix typo in readme 2019-03-18 06:09:06 -07:00
static.d.ts
tsconfig.json Don't attempt to type check compiled assets 2019-02-16 06:19:40 -08:00
yarn.lock Upgrade Prettier 2019-03-22 16:37:58 -07:00

Travis Codecov Discord

Webamp

A reimplementation of Winamp 2.9 in HTML5 and JavaScript.

As seen on TechCrunch, Motherboard, Gizmodo, Hacker News (1, 2, 3, 4), and elsewhere.

Give it a try!

Screenshot of Webamp

Works in modern versions of Edge, Firefox, Safari and Chrome. IE is not supported.

Features

Check out this Twitter thread for an illustrated list of features: https://twitter.com/captbaritone/status/961274714013319168

Use Webamp in your own project

Its possible to use Webamp as a media player on your own website. In fact, the Internet Archive offers it as an optional player for all of their archived audio tracks. Read more.

For examples of how to add Webamp to your projects, check out out examples/ directory.

See the usage documentation for more detailed information.

About This Repository

This repository contains a number of different things:

  1. ./: The code for the Webamp NPM module
  2. ./demo: The code for the demo site which lives at webamp.org
  3. ./examples: A few small examples showing how to use the NPM module
  4. ./experiments: A few small projects that are either related to Webamp, or may some day be a part of Webamp

Development

I do most development by starting the demo site in dev mode and iterating that way. The following commands will install all dependencies, run an initial development build and then start a local server. Every time you save a file, it will rebuild the bundle and automatically refresh the page.

# Clone the repo
cd webamp
# __Note:__ Please use yarn over npm, since yarn will respect our `yarn.lock` file
yarn

http://localhost:8080/ should automatically open in your browser.

# Run tests and lint checks
yarn test

Building the demo site (webamp.org)

To do an optimized build of the demo site, you can run:

yarn run build

If you wish to test this build locally, run:

yarn run serve

Then open the local ip/port that is output to the console in your browser.

Building the NPM module

The NPM module is built separately from the demo site. To build it run:

yarn run build-library

This will write files to ./built.

Testing

yarn test

This will run the tests the linter and the type checker.

To update snapshots run

yarn test -u

Deploying the Demo Site

Netlify watches GitHub for new versions of master. When a new version is seen, it is automatically built using npm run build and pushed to the server. Additionally, Netlify will run a build on every pull request and include a link under the heading "Deploy preview ready!". This enables easy high level testing of pull requests.

In short, deploying should be as simple as pushing a commit to master.

Additionally, if you want to fork the project, deploying should be as simple as setting up a free Netlify account.

Advanced Usage

There are some "feature flags" which you can manipulate by passing a specially crafted URL hash. Simply supply a JSON blob after the # of the URL to change these settings:

  • skinUrl (string) Url of the default skin to use. Note, this file must be served with the correct Allows Origin header.
  • audioUrl (string) Url of the default audio file to use. Note, this file must be served with the correct Allows Origin header.
  • initialState (object) Override the initial Redux state. Values from this object will be recursively merged into the actual default state.

Note: These are intended mostly as development tools and are subject to change at any time.

Community

Join our community chat on Discord: https://discord.gg/fBTDMqR

There are a few related projects that have communites:

Reference

Predecessors

  • Webamp2x An impressive implementation from 2002(!).
  • JsAmp An implementation from 2005 by @twm (via Hacker News).
  • LlamaCloud Comp From 2011 by Lee Martin (via Twitter)
  • Winamp em HTML5 e Javascript In 2010 a developer named Danilo posted one of his HTML5 experiments: "an audio player simulating good old Winamp". You will have to download the zip file.
  • JuicyDrop An HTML5 implementation with less emphasis on being true to the skin, but fully featured visualizations. @cggaurav is keeping it alive on GitHub
  • Spotiamp The folks at Spotify reimplemented Winamp as a frontend for Spotify. Not in a browser, and only runs on Windows.

Thanks

  • Butterchurn, the amazing Mikdrop 2 WebGL implementation. Built and integrated into Webamp by: jberg
  • Research and feature prototyping: @PAEz
  • Beta feedback, catching many small UI inconsistencies: LuigiHann
  • Beta feedback and insider answers to obscure Winamp questions: Darren Owen
  • Donating the webamp NPM module name: Dave Eddy

Thank you to Justin Frankel and everyone at Nullsoft for Winamp which inspired so many of us.

License

While the Winamp name, interface, and, sample audio file are surely property of Nullsoft, the code within this project is released under the MIT License. That being said, if you do anything interesting with this code, please let me know. I'd love to see it.