搜索插件、代码仓与 APP 分类

插件详情v0.0.1

alquran_cloud

quran.cloud API 的非官方 Dart 客户端封装,用于访问古兰经圣书

AndroidiOSWebmacOSWindowsLinux
近 30 天下载
58
喜欢数
29
Pub 分数
140

安装插件

flutter pub add alquran_cloud

插件介绍

基于插件公开信息、社区数据与项目使用情况整理的选型参考。

alquran_cloud 包是 quran.cloud API 的非官方 Dart 客户端封装,使开发者能够轻松访问和使用圣书《古兰经》的多种格式。它提供了一个简洁直观的接口,用于获取古兰经经文、章节、翻译以及塔夫西尔(注释)。该包专为跨平台使用而设计,支持 Android、iOS、Web、macOS、Windows 和 Linux。该包简化了将 Quranic 内容集成到需要古兰经内容的 Flutter 应用中的过程,非常适合宗教、教育或虔诚类应用。

适合场景

  • 将古兰经文本集成到移动应用中
  • 显示翻译和塔夫西尔
  • 构建《古兰经》阅读和学习工具
  • 创建多语言伊斯兰教育应用程序
  • 通过缓存实现离线访问古兰经

主要特点

  • 获取古兰经数据的简单API
  • 支持多种翻译和诵读
  • 跨平台兼容性
  • 内置错误处理
  • 轻量且易于集成

适合对象

  • Flutter 开发者构建伊斯兰应用程序
  • 教育类应用程序创作者
  • 宗教内容平台
  • 需要准确古兰经引用的应用程序
  • 使用 quran.cloud API 的开发人员

使用建议

  • 需要互联网连接以获取实时数据
  • 受限于 quran.cloud API 提供的功能
  • Quran.cloud 的官方认可
  • 可能需要额外的逻辑来实现离线功能
  • 依赖外部API的稳定性

原始 README

以下为关联源码仓库的 README 原文快照,最新内容请访问源码仓库。

Alquran Cloud

unofficial api wrapper for the free islamic api alquran.cloud usage

void main(List<String> args) async {
  /// to enable logs (disabled by default)
  quran_cloud.quranCloud.enableLogs = true;

  /// use edition identifer to determine which edition of the quran to get
  final allEditions = await quran_cloud.getAllEditions();

  /// also you can query the edition you want
  final editionsQuery = await quran_cloud.getAllEditions(
    format: 'text', // or `audio`
    language: 'ar', // use .getEditionSupportedLanguages(); to get the all available languages
    type: 'quran', // user .getEditionTypes() to get all available types
  );

  final quran = await quran_cloud.getQuranByEdition(allEditions.first);

  /// get surah by number and edition
  final surah = await quran_cloud.getSurahByEdition(1, editionsQuery.first);

  /// get aya by number and edition
  final aya = await quran_cloud.getAyaByNumber(2, editionsQuery.first);

  print(aya.text); // الْحَمْدُ لِلَّهِ رَبِّ الْعَالَمِينَ

Endpoints

  • [x] Editions
  • [x] Quran
  • [x] Juz
  • [x] Surah
  • [x] Aya
  • [ ] Manzil
  • [ ] Ruku
  • [ ] Page
  • [ ] Hizb
  • [ ] Quarter
  • [ ] Sajda
  • [ ] Meta
  • [x] CDM (audio/image)

Features

  • [ ] cache (awaiting this PR https://github.com/hurshi/dio-http-cache/pull/84)
  • [ ] prayer times
  • [ ] docs
  • [ ] re-tray

所属分类

依赖

依赖清单 3 项

源码仓库

使用此插件的项目

暂无相关数据。