Note: A Mapbox API key is required for this project to work correctly.
NatureScape is a web application designed to provide users with a platform to share and explore nature photography. Users can create profiles, upload images, provide feedback, and interact with other users' content.
NatureScape allows users to create an account, upload their nature photographs, and share them with the community. Users can also view, like, and comment on other users' photos. The application includes features such as dark mode, user feedback, and profile management.
- User authentication and profile management
- Image upload and display
- Feedback system for user interactions
- Dark mode toggle
- Responsive design for various devices
- Node.js
- npm (Node Package Manager)
- MongoDB
- Git
Note: Please use images from the test_images
folder when uploading photos.
-
Install Homebrew (if not already installed):
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
-
Install Git:
brew install git
-
Download Git:
Download Git from git-scm.com.
-
Install Git:
Run the downloaded installer and follow the on-screen instructions.
git clone https://github.com/BobbyBoy101/NatureScape.git
cd NatureScape
-
Install Homebrew (if not already installed):
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
-
Install Node.js and npm:
brew install node
-
Install MongoDB:
brew tap mongodb/brew brew install [email protected]
-
Install Node.js and npm:
Download and install Node.js from nodejs.org.
-
Install MongoDB:
Download and install MongoDB from mongodb.com.
Create a .env
file in the root directory and add the following environment variable:
MAPBOX_API_KEY=<your_mapbox_api_key>
Note: Replace <your_mapbox_api_key>
with your actual Mapbox API key. The project will not work without a valid Mapbox API key.
-
Install the dependencies:
npm install
-
Seed the database:
npm run seed
Note: Windows users may run into an issue when seeding based on computer preferences connecting using IPv6. To resolve this issue, modify the settings.js file in the config folder as follows:
Change
serverUrl: 'mongodb://localhost:27017/',
to
serverUrl: 'mongodb://127.0.0.1:27017/',
-
Start the server:
npm start
The application will be available at http://localhost:3000
.
- Create an Account: Navigate to the sign-up page and create a new account.
- Upload Images: Once logged in, you can upload your nature photographs.
- View and Interact: Browse through the images uploaded by other users, like, and comment on them.
- Dark Mode: Toggle dark mode using the switch in the navigation bar.
- Provide Feedback: Submit feedback for other users' profiles.
app.js
: Main application file that sets up the server and middleware.routes/
: Contains route handlers for different parts of the application.public/
: Static files such as CSS, JavaScript, and images.views/
: Handlebars templates for rendering HTML pages.data/
: Contains data access functions for interacting with the database.config/
: Configuration files for the application.
Contributions are welcome! Please fork the repository and create a pull request with your changes.
This project is licensed under the MIT License.
For any questions or suggestions, please contact the project maintainers at [email protected].