src/api.js
// Get the image details of a specific album or playlist.
Get the image details of a specific album or playlist.
Get the image details of a specific album or playlist .
function extractImageDetails({ images }) {
  const { url: image_url, width: image_width, height: image_height } =
    images
      .slice()
      .filter(image => image.width >= CONFIG.DEFAULT_IMAGE_DIMENSION)
      .reverse()[0] ||
    images[0];
  return {
    image_url,
    image_width,
    image_height
  };
}
function extractImageDetails ( { images } ) { const { url : image_url , width : image_width , height : image_height } = images . slice ( ) . filter ( image => image . width >= CONFIG . DEFAULT_IMAGE_DIMENSION ) . reverse ( ) [ 0 ] || images [ 0 ] ; return { image_url , image_width , image_height } ; }
Get the image details of a specific album or playlist.
Get the image details of a specific album or playlist .
// Images are sorted from largest to smallest.