imitatio 1.1.0 copy "imitatio: ^1.1.0" to clipboard
imitatio: ^1.1.0 copied to clipboard

Generate different types of fake data in multiple languages.

imitatio #

Imitatio allows generation of different types of fake data in multiple languages.

Inspired by mimesis.

Usage #

Imitatio has many classes that can be used to generate fake data. For example, class Person has various methods for personal information:

import 'package:imitatio/imitatio.dart';

final person = Person();
print(person.fullName()); // "Kristofer Livingston"
print(person.email(domains: ['example.com']); // "complaints1927@example.com"
print(person.phoneNumber(mask: "1-2##-3##-4##5")); // "1-224-322-4755"

// Generate data for specific locale (default is Locale.en)
final dePerson = Person(locale: Locale.de);
print(dePerson.fullName()); // Lorelei Krämer
print(dePerson.occupation); // Dolmetscher / Dolmetscherin
print(dePerson.university); // Universität Karlsruhe

// Generate data with specific seed (internal state of random generator)
final seeded1 = Person(seed: 420);
final seeded2 = Person(seed: 420);
print(seeded1.fullName()); // Maurice Lynn
print(seeded2.fullName()); // Maurice Lynn
copied to clipboard

Full API reference and documentation can be found here.

License #

MIT. See LICENSE file for more information.

0
likes
150
points
31
downloads

Publisher

unverified uploader

Weekly Downloads

2024.09.22 - 2025.04.06

Generate different types of fake data in multiple languages.

Repository (GitHub)

Documentation

API reference

License

MIT (license)

Dependencies

crypto

More

Packages that depend on imitatio