Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

music-metadata-browser

Package Overview
Dependencies
Maintainers
1
Versions
88
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

music-metadata-browser - npm Package Compare versions

Comparing version 2.1.3 to 2.1.4

2

lib/index.d.ts
import { IAudioMetadata, IOptions } from 'music-metadata/lib/type';
import * as mm from 'music-metadata/lib/core';
export { IPicture, IAudioMetadata, IOptions, ITag, INativeTagDict, IChapter } from 'music-metadata/lib/type';
export { parseBuffer, parseFromTokenizer, orderTags, ratingToStars, IFileInfo } from 'music-metadata/lib/core';
export { parseBuffer, parseFromTokenizer, orderTags, ratingToStars, IFileInfo, selectCover } from 'music-metadata/lib/core';
/**

@@ -6,0 +6,0 @@ * Parse audio Stream

"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.fetchFromUrl = exports.parseBlob = exports.parseReadableStream = exports.parseNodeStream = exports.ratingToStars = exports.orderTags = exports.parseFromTokenizer = exports.parseBuffer = void 0;
exports.fetchFromUrl = exports.parseBlob = exports.parseReadableStream = exports.parseNodeStream = exports.selectCover = exports.ratingToStars = exports.orderTags = exports.parseFromTokenizer = exports.parseBuffer = void 0;
const initDebug = require("debug");

@@ -14,2 +14,3 @@ const mm = require("music-metadata/lib/core");

Object.defineProperty(exports, "ratingToStars", { enumerable: true, get: function () { return core_1.ratingToStars; } });
Object.defineProperty(exports, "selectCover", { enumerable: true, get: function () { return core_1.selectCover; } });
/**

@@ -16,0 +17,0 @@ * Parse audio Stream

{
"name": "music-metadata-browser",
"version": "2.1.3",
"version": "2.1.4",
"description": "Browserifed version of music-metadata",

@@ -85,3 +85,3 @@ "main": "lib/index.js",

"@types/jasmine": "^3.5.14",
"@types/node": "^14.6.4",
"@types/node": "^14.10.0",
"coveralls": "^3.1.0",

@@ -112,3 +112,3 @@ "del-cli": "^3.0.1",

"debug": "^4.0.1",
"music-metadata": "^7.1.0",
"music-metadata": "^7.2.0",
"readable-stream": "^3.6.0",

@@ -115,0 +115,0 @@ "readable-web-to-node-stream": "^2.0.0",

@@ -227,2 +227,20 @@ [![Build Status](https://travis-ci.org/Borewit/music-metadata-browser.svg?branch=master)](https://travis-ci.org/Borewit/music-metadata-browser)

#### selectCover function
Select cover image based on image type field, otherwise the first picture in file.
```ts
export function selectCover(pictures?: IPicture[]): IPicture | null
```
```js
import * as mm from 'music-metadata';
(async () => {
const {common} = await mm.parseFile(filePath);
const cover = mm.selectCover(common.picture); // pick the cover image
}
)();
```
### Options

@@ -229,0 +247,0 @@ * `duration`: default: `false`, if set to `true`, it will parse the whole media file if required to determine the duration.

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc