Socket
Book a DemoInstallSign in
Socket

quran-db

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

quran-db

Quran text, translation, audio URLs, and details of pages, juz, surah, ayah, place of revelation etc.

latest
Source
npmnpm
Version
1.2.4
Version published
Weekly downloads
4
300%
Maintainers
1
Weekly downloads
 
Created
Source

npm package pub package

Quran text, translation, audio URLs, and details of pages, juz, surah, ayah, place of revelation etc.

Constants:

  • basmala - The constant 'بِسْمِ ٱللَّهِ ٱلرَّحْمَٰنِ ٱلرَّحِيمِ'
  • sajdah - The constant 'سَجْدَةٌ'
  • totalJuzCount - The constant total juz count
  • totalMadaniSurahs - The constant total of madani surahs
  • totalMakkiSurahs - The constant total of makki surahs
  • totalPagesCount - The most standard and common copy of Arabic only Quran total pages count
  • totalSurahCount - The constant total surah count
  • totalVerseCount - The constant total verse count

Functions:

Juz:

  • getJuzNumber(surahNumber, verseNumber) - Takes [surahNumber] & [verseNumber] and returns Juz number
  • getSurahAndVersesFromJuz(juzNumber) - Takes [juzNumber] and returns a map containing Surah and Verse numbers

Surah:

  • getSurahName(surahNumber) - Takes [surahNumber] and returns the Surah name
  • getSurahNameArabic(surahNumber) - Takes [surahNumber] returns the Surah name in Arabic
  • getSurahNameEnglish(surahNumber) - Takes [surahNumber] returns the Surah name in English
  • getSurahNameTurkish(surahNumber) - Takes [surahNumber] returns the Surah name in Turkish
  • getPlaceOfRevelation(surahNumber) - Takes [surahNumber] and returns the Place of Revelation (Makkah / Madinah) of that Surah
  • getVerseCount(surahNumber) - Takes [surahNumber] and returns the count of total Verses in that Surah

Verse:

  • getVerse(surahNumber, verseNumber, {verseEndSymbol}) - Takes [surahNumber], [verseNumber] & [verseEndSymbol] (optional) and returns the Verse in Arabic
  • getVerseEndSymbol(verseNumber, {arabicNumeral}) - Takes [verseNumber], [arabicNumeral] (optional) and returns '۝' symbol with verse number
  • isSajdahVerse(surahNumber, verseNumber) - Takes [surahNumber], [verseNumber] and returns true if verse is sajdah verse
  • getVerseTranslation(surahNumber, verseNumber, {verseEndSymbol, translation}) - Takes [surahNumber], [verseNumber], [verseEndSymbol] (optional) & [translation] (optional) and returns verse translation

Page:

  • getPageData(pageNumber) - Takes [pageNumber] and returns a list containing Surahs and the starting and ending Verse numbers in that page
  • getPageNumber(surahNumber, verseNumber) - Takes [surahNumber], [verseNumber] and returns the page number of the Quran
  • getSurahCountByPage(pageNumber) - Takes [pageNumber] and returns total surahs count in that page
  • getSurahPages(surahNumber) - Takes [surahNumber] and returns the list of page numbers of that surah
  • getVerseCountByPage(pageNumber) - Takes [pageNumber] and returns total verses count in that page
  • getVersesTextByPage(pageNumber, {verseEndSymbol, surahSeperator, customSurahSeperator}) - Takes [pageNumber], [verseEndSymbol], [surahSeperator] & [customSurahSeperator] and returns the list of verses in that page

URLs:

  • getAudioURLBySurah(surahNumber) - Takes [surahNumber] and returns audio URL of that surah
  • getAudioURLByVerse(surahNumber, verseNumber) - Takes [surahNumber] & [verseNumber] and returns audio URL of that verse
  • getAudioURLByVerseNumber(surahNumber) - Takes [verseNumber] and returns audio URL of that verse
  • getJuzURL(juzNumber) - Takes [juzNumber] and returns Juz URL (from Quran.com)
  • getSurahURL(surahNumber) - Takes [surahNumber] and returns Surah URL (from Quran.com)
  • getVerseURL(surahNumber, verseNumber) - Takes [surahNumber] & [verseNumber] and returns Verse URL (from Quran.com)

Search:

  • searchWords(words) - Takes an array of words [words] and returns a map containing no. of occurences and result of the word search in the arabic quran text
  • searchWordsInTranslation(words, {translation}) - Takes an array of words [words] and [translation] (optional) and returns a map containing no. of occurences and result of the word search in the traslation

Translations:

  • English (Saheeh International) - Translation.enSaheeh
  • English (Clear Quran) - Translation.enClearQuran
  • French (Muhammad Hamidullah) - Translation.frHamidullah
  • Turkish - Translation.trSaheeh
  • Malayalam (Cheriyamundam Abdul Hameed and Kunhi Mohammed Parappoor) - Translation.mlAbdulHameed
  • Farsi - Translation.faHusseinDari
  • Portuguese - Translation.portuguese
  • Italian - Translation.itPiccardo
  • Dutch - Translation.nlSiregar
  • Russian - Translation.ruKuliev
  • Bengali - Translation.bengali
  • Chinese - Translation.chinese
  • Swedish - Translation.swedish
  • Spanish - Translation.spanish
  • Urdu - Translation.urdu
  • Indonesian - Translation.indonesian

SurahSeperators:

  • SurahSeperator.none
  • SurahSeperator.surahName
  • SurahSeperator.surahNameArabic
  • SurahSeperator.surahNameEnglish
  • SurahSeperator.surahNameTurkish

Keywords

quran

FAQs

Package last updated on 08 Oct 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts