Giter VIP home page Giter VIP logo

storestash's Introduction

StoreStash

App for CS 4261: Mobile Apps & Services, Spring 2020.

2nd place winner of the Georgia Tech Convergence Innovation Competition: Global Response.

Live demo: https://storestash.now.sh/

Video demo: https://vimeo.com/413484123. See https://vimeo.com/402859833 for an abridged version.

Running locally

Backend

cd backend

Create a MongoDB database, perhaps on MongoDB Atlas. Remember to whitelist your connection IP address. Copy .env.example into a new .env file and replace the MongoDB in MONGODB_URI with your actual one.

Install dependencies: npm install

Then, to start the server locally, run

npm run build
npm start

In production, if you end up using cookies, you should change the SESSION_SECRET environment variable.

Web frontend

cd frontend

Install dependencies: npm install

Serve the app: npm start

The frontend is currently set to interact with the server at https://storestash.herokuapp.com. You can change the URL that requests are made to by editing frontend/wretcher.ts.

Android frontend

To test with an Android device:

  • Download the storestash.apk file from 'android/apk_file/storestash.apk' onto your device.
  • When you open the file you're device will allow you to install and run the application.

To test with your computer:

  • Download Android Studio
  • In Android Studio, create an Android Virtual Device (AVD) that the emulator can use to run apps.
  • Run an emulated device.
  • Download the storestash.apk file from android/apk_file/storestash.apk onto your device.
  • Drag and drop the apk file onto the emulated device and it will install the app. Run the installed app.

Deploying

Frontend: Vercel

Note that currently, deploying the frontend to Heroku fails. Instead, you can deploy it with Vercel.

Backend: Heroku

Install the Heroku CLI, and then set it up:

npm install -g heroku # adds the heroku command to CLI on Windows
heroku login

Add Heroku remote. Replace the URLs here with the ones for your Heroku app.

git remote add storestash-app-heroku https://git.heroku.com/storestash-app.git
git remote add storestash-backend-heroku https://git.heroku.com/storestash.git

For the following instructions, make sure your command line is in the StoreStash folder, not backend/ or react_ionic

Push from the master branch (non-force):

git subtree push --prefix frontend storestash-app-heroku master
git subtree push --prefix backend storestash-backend-heroku master

Force push from the master branch:

git push storestash-app-heroku `git subtree split --prefix frontend master`:master --force
git push storestash-backend-heroku `git subtree split --prefix backend master`:master --force

Other commands that may be helpful:

# Force push from local end_to_end branch
git push heroku `git subtree split --prefix backend end_to_end`:master --force
heroku logs -a storestash
# Supposedly this helps with multiple users pushing
git push heroku $(git subtree split --prefix=server $(git symbolic-ref --short -q HEAD)):master --force

Android

The APK was made using https://github.com/xtools-at/Android-PWA-Wrapper

Ionic also has its own way of building Android bundles.

storestash's People

Contributors

dependabot[bot] avatar gabrielw98 avatar kksharma99 avatar ml-chen avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Forkers

ml-chen

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.