This seeding file, seeding.ts, is designed to populate the database with initial data. The file will create a dummy seller and six listings, with two listings for each category (Housing, For Sale, and Fooding). Images for each listing will be sourced from the public folder, and linked to the created listings in the database.
This seed data provides users with a quick way to see the platform in action, even if the database is initially empty.
Purpose of the Seeding File
When a user sets up the project for the first time, the database is usually empty, which makes it challenging to explore or test the application's features. Seeding the database with sample listings allows users to:
Quickly interact with and test various features of the application.
See how data is structured and displayed on different pages.
Experience the user flow without needing to manually add initial data.
Description
Seeding Database with Initial Listings
Overview
This seeding file,
seeding.ts
, is designed to populate the database with initial data. The file will create a dummy seller and six listings, with two listings for each category (Housing, For Sale, and Fooding). Images for each listing will be sourced from thepublic
folder, and linked to the created listings in the database.This seed data provides users with a quick way to see the platform in action, even if the database is initially empty.
Purpose of the Seeding File
When a user sets up the project for the first time, the database is usually empty, which makes it challenging to explore or test the application's features. Seeding the database with sample listings allows users to:
Screenshots
No response
Checklist