This directory contains examples showcasing the use of Snaplet's seed
feature. Snaplet seed
helps create realistic, production-like data for your development databases, facilitating efficient and practical testing and development.
Snaplet seed
is a powerful tool for seeding your database with data that mimics real-world scenarios. It leverages your database schema to seed data that respects the relationships and constraints defined within your schema.
Each example in this directory demonstrates a unique use case of the seed
feature, ranging from simple data seeding to more complex scenarios involving data relationships and constraints.
- Define Your Database Schema: Before generating data, ensure your database schema is defined and reflects the relationships between different data entities.
- Create a Data Generation Plan: Translate your requirements into a data generation plan within the Snaplet configuration.
- Run the seed script: Use
@snaplet/seed
to generate a seed script to populate your database with the seedd data.
For more detailed instructions, refer to the README within each example directory.