Skip to content

subekti404dev/quran-kemenag

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

view on npm npm module downloads per month

Quran Kemenag

Al-Quran data from kemenag (https://quran.kemenag.go.id)

How to Install

npm install quran-kemenag
# or
yarn add quran-kemenag

How to Use

// in common JS
const QuranKemenag = require("quran-kemenag");

// in typescript
import QuranKemenag from "quran-kemenag";

const quran = new QuranKemenag();

// Get List of Surah
quran.getListSurah(
    keyword      // optional, search keyword for surah name
    )
    .then((data) => {
        // data handling here
    })
    .catch((error) => {
        // error handling here
    });


// Get Surah Data
const options = {
    include_verse: true,
    verses_limit: 2,
    verses_offset: 1
}
quran.getSurah(
    1,          // required, surah id or surah number
    options     // optional
    )
    .then((data) => {
        // data handling here
    });
    .catch((error) => {
        // error handing here
    })

About

a nodejs module to fetch quran data from kemenag

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published