Skip to content

4. Usage

Hanif Dwy Putra S edited this page Nov 7, 2021 · 2 revisions

How to use otakudesu-scraper module?

Very easy, you only need to import it. And run it.

Examples

import { OtakudesuInstance } from 'otakudesu-scraper';

const otakudesu = new OtakudesuInstance(); // create otakudesu instance
// Well, you can code it like this: "new OtakudesuInstance('https://otakudesumoved.com');"
// It means, you can custom otakudesu website when the website is down or moved. Default: https://otakudesu.vip

otakudesu.getAnime('Boruto').then(console.log); // execute 'getAnime' method with 'Boruto' as the first parameter (anime name).
// You can change 'Boruto' to another anime name, such as 'One Piece', or 'Tokyo Revengers'
// And ".then(console.log);" will print the method results.

Easy right?

Clone this wiki locally