lrc2json

1.0.1 • Public • Published

lrc2json

npm version

A simple module that parses LRC format to JSON object.

Install

Using npm

npm install --save lrc2json

Usage

const lrc2json = require('lrc2json');
let lrcJSON = lrc2json(lrcString);

Sample Input

[ti: Title]
[ar: Artist]
[au: Author]
[al: Album]
[by: Creator]
[length: 03:00]
[re: Editor]
[ve: Version]

[00:00.00]Begin
[03:00.00]End

Sample Output

{
  "ti": "Title",
  "ar": "Artist",
  "au": "Author",
  "al": "Album",
  "by": "Creator",
  "length": "03:00",
  "re": "Editor",
  "ve": "Version",
  "lyrics": [
    {
      "time": "00:00.00",
      "text": "Begin"
    },
    {
      "time": "03:00.00",
      "text": "End"
    }
  ]
}

Readme

Keywords

Package Sidebar

Install

npm i lrc2json

Weekly Downloads

1

Version

1.0.1

License

MIT

Unpacked Size

4.3 kB

Total Files

6

Last publish

Collaborators

  • qriousgabriel