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

套件詳情v4.8.2

more

更多 Dart — 真的。輕鬆收集、反覆運算、快取、數學、比對、排序和格式化。

AndroidiOSWebmacOSWindowsLinux
近 30 天下載
36.4萬
喜歡數
86
Pub 分數
160

安裝套件

flutter pub add more

套件介紹

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

More Dart 是一個實用程式套件,透過為集合操作、迭代、快取、數學運算、模式比對、排序和格式化提供便利的方法來擴展 Dart 的核心功能。它透過提供直覺且可鏈式呼叫的 API 來提升開發人員的生產力,適用於常見任務。此套件設計輕巧且易於整合,支援所有主要平台,包括 Android、iOS、Web、macOS、Windows 和 Linux。對於希望簡化重複性編碼模式並提升程式碼可讀性的開發者而言,這是一個理想的選擇。

適用情境

  • 資料轉換管道
  • 快取頻繁存取的資料
  • 對集合進行數學計算
  • 字串和格式處理
  • 排序和篩選複雜資料
  • 集合中的模式匹配

主要特色

  • 擴展核心 Dart 類別,提供有用的程式方法
  • 可鏈式呼叫且流暢的 API 設計
  • 支援跨平台開發
  • 輕量且無依賴
  • 全面的實用函數
  • 透過 pub add 輕鬆整合

適合對象

  • 尋求增強實用函數的 Dart 開發人員
  • 需要頻繁資料處理的專案
  • 致力於減少樣板程式碼的團隊
  • 針對多個平台的應用程式
  • 專注於程式碼清晰度與可維護性的開發者

使用建議

  • 如果擴展核心類型,可能會引入細微的行為變更
  • 由於抽象層的存儲,不適合用於對效能要求極高的熱路徑
  • 除了基本範例之外,文件內容有限
  • 最好與強類型程式設計實踐結合使用
  • 需要熟悉 Dart 擴展方法

原始 README

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

More Dart — Literally

Pub Package Build Status Code Coverage GitHub Issues GitHub Forks GitHub Stars GitHub License

A collection of extensively tested extensions that make Dart a better place:

Library Description
async Extensions to Stream.
cache Caching strategies and their expiry policy.
char_matcher Character classes, their composition, and operations on strings.
collection Extensions to Iterable and new collection types.
comparator Common comparators, and extensions to perform advanced operations.
diff Tools for comparing lists.
feature Information about the runtime environment.
functional Types and features known from functional programming.
graph Graph-theory objects and algorithms.
interval Continuous interval data type over a comparable type.
math Common mathematical functions.
number Number types: fraction, complex, quaternion.
printer Fluent interface to configure sophisticated formatter.
temporal Extensions to DateTime and Duration types.
tuple Tuple extension methods on generic records.

And there are more to come ...

This library is open source, stable and well tested. Development happens on GitHub. Feel free to report issues or create a pull-request there. General questions are best asked on StackOverflow.

The package is hosted on dart packages. Up-to-date class documentation is created with every release.

Misc

Installation

Follow the installation instructions on dart packages.

Import the all-including parent package:

import 'package:more/more.dart';

Or one or more of the specific packages into your Dart code:

import 'package:more/async.dart';
import 'package:more/cache.dart';
import 'package:more/char_matcher.dart';
import 'package:more/collection.dart';
import 'package:more/comparator.dart';
import 'package:more/diff.dart';
import 'package:more/feature.dart';
import 'package:more/functional.dart';
import 'package:more/graph.dart';
import 'package:more/interval.dart';
import 'package:more/math.dart';
import 'package:more/number.dart';
import 'package:more/printer.dart';
import 'package:more/temporal.dart';
import 'package:more/tuple.dart';
Contributing

The goal of the library is to provide a loose collection of carefully curated utilities that are not provided by the Dart standard library. All features must be well tested. New features must have significant advantages over alternatives, such as code reduction, readability improvement, speed increase, memory reduction, or improved accuracy. In case of doubt, consider filing a feature request before filing a pull request.

History

This library started in April 2013 as I was working through the puzzles of Project Euler and encountered some missing features in Dart. Over time the code grew and became more useful in many other places, so I created this reusable library.

Some parts of this library are inspired by similar APIs in Google Guava (Google core libraries for Java) and Apache Commons (a repository of reusable Java components).

License

The MIT License, see LICENSE.

所屬分類

依賴

依賴清單 4 項

原始碼儲存庫

使用此套件的專案