1.1.8 • Published 6 years ago

mayumi-core v1.1.8

Weekly downloads
1
License
MIT
Repository
github
Last release
6 years ago

mayumi-core

Download Manga.

Install

$ npm install --save mayumi-core

Requirements

Usage

Download

const { Downloader } = require('mayumi-core')

const dl = new Downloader({
    formats: ['png', 'jpg', 'pdf']
})

const task = {
    url: 'http://mangafox.me/manga/onepunch_man/v11/c056.1/1.html',
    formats: ['png', 'jpg']
}

dl.add(task)

Utils

const { Utils } = require('mayumi-core')

Utils.search('mahou')
    .then( mangas => {
        // process mangas
    })
    .catch( err => {
        // error
    })

Utils.getChapters('http://mangafox.me/manga/onepunch_man/')
    .then( mangas => {
        // process mangas
    })
    .catch( err => {
        // error
    })

Downloader

Options

optiontypedescription
formatsArrayfile formats. atm supported jpg, png and pdf
savePathStringthe savepath. the standard savepath is the homedir + mayumi

Events

eventreturn typedescription
finishedTask Objectreturns the Task Object when the task is finished
all-finishednoneoccurs when all tasks are finished
errorError Objectreturns an error when an error occurs
progressProgress Objectreturns an Progress object when progress was made in a task

Progress Values

  • get image urls
  • get info
  • download images
  • convert images
  • save manga

Utils

search(s, opts)

Takes a String and an opts Object and returns an array with all matching manga names and urls. if the manga is found on multiple sites it returns the same manga multiple times but with diffrent urls. The returned Objects have a name and a url property.

getChapters(url)

Takes a String and returns all available chapters + urls for the requested manga as an array. The returned Objects have a chapter and a url property.

Supported Sites

Can convert to the following formats

  • jpg
  • png
  • pdf

License

MIT © sys0

Support me

  • Bitcoin 13bRt1QBQNDEffFHubqgcgSSUopKLTaJqx
  • Litecoin LdVRWXYUAwTw51ZLxfcP2oZiVS17cgBHha
1.1.8

6 years ago

1.1.7

7 years ago

1.1.6

7 years ago

1.1.5

7 years ago

1.1.4

7 years ago

1.1.3

7 years ago

1.1.2

7 years ago

1.1.1

7 years ago

1.1.0

7 years ago

1.0.17

7 years ago

1.0.16

7 years ago

1.0.15

7 years ago

1.0.14

7 years ago

1.0.13

7 years ago

1.0.12

7 years ago

1.0.11

7 years ago

1.0.10

7 years ago

1.0.9

7 years ago

1.0.8

7 years ago

1.0.7

7 years ago

1.0.6

7 years ago

1.0.5

7 years ago

1.0.4

7 years ago

1.0.3

7 years ago

1.0.2

7 years ago

1.0.1

7 years ago

1.0.0

7 years ago

0.0.4

7 years ago

0.0.3

7 years ago

0.0.2

7 years ago

0.0.1

7 years ago