Coder Social home page Coder Social logo

fedemartinm / reforum Goto Github PK

View Code? Open in Web Editor NEW

This project forked from proshoumma/reforum

0.0 0.0 0.0 972 KB

A minimal forum board application. Built on top of React-Redux frontend, ExpressJS-NodeJS backend (with PassportJS for OAuth) and MongoDB databse.

Home Page: https://reforum-app.herokuapp.com/

License: MIT License

JavaScript 87.11% HTML 0.72% CSS 12.17%

reforum's Introduction

logo

ReForum

A minimal forum application built with the following technologies:

Demo app is deployed on Heroku. Please check it out: https://reforum-app.herokuapp.com/

Application Features

  • Users can post a discussion
  • Users can reply their opinions regarding discussion
  • Users can favorite discussions
  • Users have their own profile page
  • Admin can create new forum categories
  • Admin have a lot of power over every users discussions and opinions :-p

Documentations

Home View

home view

Admin View

admin view

Deploy on you own server

Please make sure you have following software installed in your system:

  • Node.js > 6.0
  • NPM / Yarn
  • Git
  • MongoDB

First we need to clone the repository:

$ git clone https://github.com/shoumma/ReForum

Then we have to install the necessary dependencies using either NPM or Yarn:

$ npm i
$ yarn

Since the app currently uses GitHub authentication, we need to configure a GitHub OAuth application. You can register a new application from this link https://github.com/settings/developers

We need to grab the following information from the OAuth application.

  • Client ID
  • Client Secret
  • Callback URL

The Callback URL is the domain where GitHub will redirect the user after a successful login. You can use a domain name or local host. But we need to append the URL with the path /api/user/authViaGitHub/callback. So, the complete url will look like: https://localhost:8080/api/user/authViaGitHub/callback

Now, we need to configure the credentials inside of the codebase. Open the file config/credentials.js add the necessary information. The file looks like this:

module.exports = {
  GITHUB_CLIENT_ID: '',
  GITHUB_CLIENT_SECRET: '',
  GITHUB_CALLBACK_URL: '',
  DBURL: '',
};

We need to provide all the information here. You can notice that we need the database url here too. My local MongoDB url looks like:

mongodb://localhost:27017/reforum

Now we are ready to run the application. You can run either run the development environment of the application which will include Hot-Reload for JS codes using Webpack and the Redux dev tool extension, or you can run the production edition. The default port for developer edition is 8080, and for production is process.env.PORT.

To run the app in development environment:

$ npm run start:dev

To run the app in production environment:

$ npm run start

Now, if you visit http://localhost:8080 (if you ran the dev), or the production URL, you will see that the application is up and running. Congratulation! But, wait a minute, it's showing you Sorry, couldn't find the forum. That is because, we didn't create any forum yet. You can now sign up via github and then visit the admin panel with the url http://localhost:8080/admin. The application is currently configured in a way that, the first user will become the admin for the system.

Here we can create new forums and that forum will be displayed in the application. The first forum will be used as default forum.

Congratulation! You now have a clone of this application in your server. :-)

Path for Future Work

  • Add search functionality
  • Add unit tests for both backend and frontend
  • Ability to change the name and logo of the site from admin panel.
  • Make the installation process more interactive
  • Add multiple theme support.

License

MIT License. Do whatever you want to do. :-)

Conclusion

The application is created with lots of โ™ฅ. Any pull request, issues and contribution is very appreciated. It would be really great if we can take this application to the next level, where it can be used as a platform for forums.

Provash Shoumma

reforum's People

Contributors

proshoumma avatar tgdn avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.