FarmStand is a simple web application built with Node.js, Express, and MongoDB for managing agricultural products.
These instructions will help you set up and run the project on your local machine.
-
Clone the repository:
git clone https://github.com/your-username/farmstand.git
-
Navigate to the project directory:
cd farmstand
-
Install Dependencies:
npm install
node index.js
Open your browser and visit http://localhost:3000/products to see the FarmStand app in action.
- View products
- Add new products
- Edit existing products
- Delete products
The main application logic is located in index.js. It connects to a MongoDB database, defines a Product model, and sets up routes for CRUD operations on products. The models/product.js file contains the product schema and model definition.
- index.js: Main application file with routes and server setup.
- views/products: Contains EJS templates for rendering HTML pages.
- models/product.js: Defines the product schema and model.
- seed.js: Seeds the database with initial product data.
- Node.js
- Express.js
- MongoDB