搜尋套件、儲存庫與 APP 分類

套件詳情v1.0.0

bible

一個簡單的應用程式,可從單一位置與多個聖經API進行互動

AndroidiOSWebmacOSWindowsLinux
近 30 天下載
101
喜歡數
21
Pub 分數
130

安裝套件

flutter pub add bible

套件介紹

根據套件公開資料產生的選型評估,僅供參考。

Bible 套件是一個 Flutter/Dart 庫,透過單一介面提供對多個聖經 API 的統一存取。它簡化了與各種聖經資料來源的整合,讓開發者能有效率地取得經文段落、搜尋文字以及擷取元資料。此套件設計用於跨平台使用,支援 Android、iOS、Web、macOS、Windows 與 Linux。該套件抽象了 API 差異,提供一致的方法來查詢聖經內容,非常適合用於信仰相關應用程式、研究工具或靈修平台。僅需透過 `flutter pub add bible` 進行最小設定,開發者即可快速將豐富的聖經內容納入其應用程式中。

適用情境

  • 聖經閱讀應用程式
  • 經文引用工具
  • 靈修和祈禱應用
  • 宗教教育平台
  • 跨平台聖經整合

主要特色

  • 統一API介面
  • 支援多種聖經來源
  • 跨平台相容性
  • 透過 pub 簡單安裝
  • 一致的數據檢索方法
  • 輕量且易於整合

適合對象

  • 開發宗教類應用程式的開發者
  • 教育軟體創作者
  • 移動和網絡應用團隊
  • 開源專案貢獻者
  • 需要聖經數據的應用程式

使用建議

  • 依賴外部聖經API
  • 可能需要處理速率限制
  • 資料格式一致性因來源而異
  • 僅限文字類經文檢索
  • 無內建快取機制
  • 需要互聯網連接以取得資料

原始 README

以下為關聯原始碼儲存庫的 README 原文快照,最新內容請造訪原始碼儲存庫。

bible

This package provides a simple interface for interacting with different bible APIs.

Usage

This package currently only supports querying these APIs:

Name Requires API key notes
esvapi yes
getbible no Does not support verse references that cross chapters. Genesis 2-3 ✅ Gensis 2:1 - 3:5 ❌
bibleorg no
bibleapi no

Simple example:

import 'package:bible/bible.dart' as Bible;
...
var passage = await Bible.queryPassage('John 3:16'); // Will default to the GetBible API
print(passage.passage) // The text from the query

An example requiring an API key:

Bible.addKeys({'esvapi': 'APITOKEN'});
var passage = await Bible.queryPassage('John 3:16', providerName:'esvapi');

You can also pass the API key as an optional parameter:

Bible.addKeys({'esvapi': 'APITOKEN'});
var passage = await Bible.queryPassage('John 3:16', key: 'APITOKEN');

You can also pass query parameters through a map. See specific API documentation for those parameters.

Bible.addKeys({'esvapi': 'APITOKEN'});
var passage = await Bible.queryPassage('John 3:16', key: 'APITOKEN', parameters: {'Map': 'of params'});

You can specify the version or provider with optional parameters.

var passage = await Bible.queryPassage('John 3:16', providerName: 'getbible', version: 'asv');

**Note:**The providerName coresponds to that in the table at the beginning of this documentation.

Every time a passage is queried, the reference_parser library tries to parse the query (i.e mispelling will automatically be corrected, shortened verse forms will be allowed). To prevent this just pass false to the useParser parameter.

var passage = await Bible.queryPassage('John 3:16', useParser: false);

If you import the providers library you can use can directly query every the providers or pass them to the queryPassage function as an optional parameter

import 'package:bible/bible.dart' as Bible;
import 'package:bible/providers.dart';
//...
var prov = GetBible();
var passage = await Bible.queryPassage('John 3:16', provider: prov);

This is the same as using the providerName parameter but if you were to create your own provider you could pass it to the function.

Note: If you create your own provider please consider contributing it back to the repository :).

Contributing

Implementing an API isn't hard, so I'm open to having people implementing and sending pull requests for different bible APIs. This is a great first issue and doesn't require extensive dart knowledge, just copy a provider already created and go from there!

APIs that need implementing:

Name Difficulty
nltapi easy
bibliaapi moderate
scriptureapi hard

For more specific information look at the contributing guidlines.

所屬分類

依賴

依賴清單 2 項

  • http^0.13.3
  • reference_parser^3.0.0

原始碼儲存庫

使用此套件的專案

暫無相關資料。