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

GitHub 代码仓othiagobruno/validatorless

无验证器

Validatorless - 一个用于验证输入的 Flutter 包

无验证器 项目封面
星标
33
复刻
11
最近推送(UTC)
2026年9月4日
项目状态
未归档

原始 README

以下为英文项目原文快照,最新内容请访问 GitHub。

Validatorless

Pub Version

This package provides a means to validate text inputs on the flutter and was inspired by Yup

Validatorless in pub.dev

how to use
dependencies:
  # Use the latest version available. Any is just a placeholder
  validatorless: any
TextFormField(
  decoration: InputDecoration(
    labelText: 'User e-mail',
  ),
  validator: Validatorless.multiple([
     Validatorless.email('The field must be an email'),
     Validatorless.required('The field is obligatory')
  ]),
)

or use

TextFormField(
  decoration: InputDecoration(
    labelText: 'CPF',
  ),
  validator: Validatorless.cpf('CPF not is valid'),
)
Validatorless options
  Validatorless.multiple(List<Validatorless>)
  Validatorless.required(String)
  Validatorless.email(String)
  Validatorless.min(int, String)
  Validatorless.max(int, String)
  Validatorless.between(int, int, String)
  Validatorless.number(String)
  Validatorless.cpf(String)
  Validatorless.cnpj(String)
  Validatorless.date(String)
  Validatorless.compare(TextEditingController, String)
  Validatorless.numbersBetweenInterval(Double, Double, String)
  Validatorless.onlyCharacters(String)
  Validatorless.regex(RegExp, String)
  Validatorless.length(int, String)
  Validatorless.phone(String) // (99) 99999-9999 or (99) 9999-9999
  Validatorless.cep(String)
  Validatorless.url(String)
  Validatorless.strongPassword(String, {int minLength})
  Validatorless.creditCard(String)
  Validatorless.placa(String)

Publishing

Pushes to master run .github/workflows/publish.yml: patch-bump pubspec.yaml (unless the push already changed the version), append CHANGELOG.md, commit with [skip ci], tag (1.3.1, no v prefix), create a GitHub Release, and dart pub publish --force.

Add a repository secret named PUB_CREDENTIALS_JSON (Settings → Secrets and variables → Actions) containing the full contents of the Dart credentials file after dart pub login:

  • Linux: ~/.pub-cache/credentials.json or ~/.config/dart/pub-credentials.json
  • macOS: ~/Library/Application Support/dart/pub-credentials.json

Do not commit that file. The workflow fails if the secret is missing.

Thiago Bruno Miranda GitHub avatar
GitHub 作者

Thiago Bruno Miranda ↗

Head | Full Stack Developer | Node.js, Golang, Flutter, React, AWS, GCP | +7 anos de experiência

Balsas, MA, 65800000
语言Dart

此仓库发布的插件

使用的依赖

依赖清单 2 项

  • flutter{"sdk":"flutter"}
  • flutter_test开发依赖{"sdk":"flutter"}

如何选择适合项目的代码仓?

先按使用场景筛选,再比较项目活跃情况,最后到原始仓库核对使用要求。

  1. 通过仓库名、作者或描述搜索,再按技术分类缩小范围。
  2. 结合星标、复刻与最近推送比较项目;星标反映社区关注,不代表质量保证。
  3. 使用前在 GitHub 核对 README、许可证与 Issues。

来源与维护

“A repository is the most basic element of GitHub.”

GitHub Docs — About repositories ↗