Skip to content
James Bradbury edited this page Jan 25, 2022 · 1 revision

All assets (images, audio, data) should be made as small as possible through compression and minification.

Data

Data should be stored in /static/data. This can contain binary files (.npy for example) or JSON data. JSON should be minified. This can be achieved with a free tool like: https://codebeautify.org/jsonminifier.

Images

Images should be saved ideally in .jpg format, and compressed as small as possible. We use ImageOptim, with at least the default settings, though it is preferable to enable the lossy settings to get evven more gains. Often the difference is negligible at high thresholds of loss.

Audio

All audio should be .mp3 format. Uncompressed formats such as .wav, .aif and .flac are too large to supply to users on the internet and will make the website on slow connections.

A tool such as ffmpeg can be used to create small .mp3 with a command-line call such as ffmpeg -i big_sound.wav -q:a 3 small_sound.mp3.

Another option is to use REAPER which offers a GUI and a lot of options for compression.

Clone this wiki locally