Skip to content

A full-stack CMS-style blog site where users can publish articles, blog posts, & thoughts; created with Node.js, MySQL, Handlebars.js, & more

Notifications You must be signed in to change notification settings

demivlkv/tech-blog

Repository files navigation

Project 14: Model-View-Controller (MVC) Challenge

Tech Blog

Writing about tech can be just as important as making it. Developers spend plenty of time creating new applications and debugging existing codebases, but most developers also spend at least some of their time reading and writing about technical concepts, recent advancements, and new technologies.

The purpose of this project was to built a CMS-style blog site - similar to a WordPress site - where developers could publish their blog posts and comment on other developers' posts as well. This application follows the MVC paradigm in its architecture structure, atilizes Handlebars.js as the templating language, Sequelize as the ORM, and the express-session npm package for authentication.

Built With:

screenshot.png

Live View:

https://frozen-sierra-30429.herokuapp.com/

Installation

  1. To install this application, git clone this repository, or download the .zip file in the dropdown after clicking the ‘Code’ button at the top of this repository—as long as it is in your local branch.
  2. Ensure Node.js is installed in your operating system.
  3. Create a .env file in the root directory with the following information, and include your MySQL username (DB_USER) and password (DB_PASSWORD) between the single quotes:
DB_NAME='tech_blog_db'
DB_USER=''
DB_PASSWORD=''
  1. Install all of the npm packages listed above via command-line in terminal.
  2. Initialize MySQL by running mysql -u root -p, and enter your password when prompted. Once loaded, enter SOURCE db/schema.sql; to create the database. Exit MySQL by entering quit; in terminal.
  3. The application can be accessed by visiting http://localhost:3001 in the browser after running the following command:
node server.js
  1. Insomnia or Postman can be used to check the backend functionality.

Usage

Feel free to use the guest account with these credentials to explore the functionality of this web application:

Username: guest Password: rlalo4fz4l

An unregistered user will be able to navigate to the homepage, login, or signup links, as well as view blog posts without being able to leave comments.

On the other hand, a registered user will have access to the dashboard, where they could create, edit, or delete posts. In addition, a registered user will have to ability to leave comments on blog posts. A logout button will be displayed in the navigation upon login.

The user's session will automatically expire after 10 minutes of idle activity.

Questions

For any questions about this repository, please contact me at demi.h@me.com.

To view more of my works, please visit my GitHub: demivlkv.

About

A full-stack CMS-style blog site where users can publish articles, blog posts, & thoughts; created with Node.js, MySQL, Handlebars.js, & more

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published