recase
4.1.0, released 4 years ago by an unverified publisher
Changes the case of input text to various conventions.
What it does
It transforms strings between different casing formats like camelCase, snake_case, PascalCase, and constantCase. Both class-based and String extension APIs are supported.
AI-written summary of version 4.1.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to format strings into snake_case, camelCase, or other standard conventions.
- You are transforming user input or API responses into consistent naming styles.
Skip it when
- You need complex internationalization or localization tools.
Strengths
- Supports a wide variety of case conventions.
- Provides convenient String extensions.
- Zero dependencies.
Weaknesses
- Limited scope restricted strictly to string casing transformations.
Setup
- Kind
- Pure Dart
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 0
import 'package:recase/recase.dart';
void main() {
String sample = 'Just_someSample-text';
print(sample.camelCase);
print(sample.constantCase);
}Alternatives
Packages that do the same job and could replace recase.
- text_comparison_score_codespark
Calculate string similarity and fuzzy matching scores using Levenshtein, Damerau-Levenshtein, and Jaro-Winkler.
57Compare - dart_quill_delta
Dart port of Quill Delta JSON format for rich-text documents
50Compare - dart_casing
Dart library for changing String case style to the desired convention.
47Compare
Works with
Packages commonly used together with recase: ones it builds on, ones built on it, and its own family.
- drift_devBuilt on recaseGenerates Dart database code from Drift table definitions as a dev‑dependency.
- injectable_generatorBuilt on recaseCode generator that creates GetIt registrations for the injectable library
- envied_generatorBuilt on recaseGenerates compile‑time Dart constants from .env files for the Envied package.
- graphql_codegenBuilt on recaseGenerate Dart serializers and client helpers from GraphQL queries and schemas.
- swagger_dart_code_generatorBuilt on recaseGenerates Dart models and Chopper API client code from Swagger and OpenAPI schemas.
- nuvigatorBuilt on recaseRouting abstraction over Flutter navigator with nested navigation and deep links
- storybook_flutterBuilt on recaseA storybook for Flutter widgets to showcase and preview isolated components.
- stacked_generatorBuilt on recaseGenerates routing and dependency‑injection boilerplate for Stacked apps.