Giter VIP home page Giter VIP logo

beer.ly's Introduction

beer.ly

Beer.ly is an application that is designed to connect users to their local breweries. View nearby beers on tap, order flights of beer, and see recommendations from your friends on Untappd.

screen shot 2017-05-11 at 10 33 25 pm screen shot 2017-05-11 at 10 36 40 pm

Tech Stack

  1. Node / Express
  2. React
  3. Mongoose/MongoDB
  4. Google Maps API
  5. StripeJS
  6. Material UI
  7. BreweryDB
  8. S3

Quick Start

Fork/Clone

git clone https://github.com/rewhsu/beer.ly.git

Install Dependencies

npm install

Run

npm start

Features

Hot Module Replacement

Lazy Script Loading

React CSS Modules

HTTPS Server / SSL Certification

Instructions on how to get set up with HTTPS

  1. Create a key.pem / cert.pem file in the root directory of the project. (Same folder as index.js). Use this command:
openssl req -x509 -newkey rsa:2048 -keyout key.pem -out cert.pem -days 30

// For passcode, type 'beerly' for now. You can change the passcode in server/middleware/SSL.js.
// For Common Name, type 'localhost'.
// For everything else, you can just leave it blank.
  1. Files have already been added to .gitignore so don't worry about adding them.
  2. Start the server as you normally would.
npm start
  1. Go to 'https://localhost:5000' to reach the server. Use https from now on. If you're using Chrome, it's going to complain that it's insecure. Just hit the 'Advanced' button and click 'Continue anyway'. You only have to do this once.

Webpack Development Middleware

API

GET /api/beers/<Brewery Name>

This endpoint is needed for the BeerList component. It makes an API request to BreweryDB to retrieve a list of available beers from a brewery.

{
  id: "yEusNN",
  name: "Acoustic Blondie",
  nameDisplay: "Acoustic Blondie",
  abv: "6",
  isOrganic: "Y",
  ...
  style: {
    category: {
      id: 5,
      name: "Belgian And French Origin Ales",
    },
    name: "Belgian-Style Blonde Ale",
    shortName: "Belgian Blonde",
    description: "Belgian-style blond ales are characterized by ...",
    ...
  }
},

GET /api/breweries/<Location>

This endpoint is needed for the BreweryList component. It makes an API request to BreweryDB to retrieve a list of available breweries at a location.

{
id: "wXmTDU",
name: "Main Brewery",
streetAddress: "563 Second Street",
locality: "San Francisco",
region: "California",
postalCode: "94107",
phone: "415-369-0900",
latitude: 37.7824892,
longitude: -122.3924905,

brewery: {
  id: "EdRcIs",
  name: "21st Amendment Brewery",
  description: "The 21st Amendment Brewery offers a variety of...",
  website: "http://www.21st-amendment.com/",
  images: {
    icon: "https://s3.amazonaws.com/brewerydbapi/brewery/EdRcIs/upload_gfSGyp-icon.png",
    medium: "https://s3.amazonaws.com/brewerydbapi/brewery/EdRcIs/upload_gfSGyp-medium.png",
    large: "https://s3.amazonaws.com/brewerydbapi/brewery/EdRcIs/upload_gfSGyp-large.png",
    squareMedium: "https://s3.amazonaws.com/brewerydbapi/brewery/EdRcIs/upload_gfSGyp-squareMedium.png",
    squareLarge: "https://s3.amazonaws.com/brewerydbapi/brewery/EdRcIs/upload_gfSGyp-squareLarge.png"
  },
  ...
},
country: { ... },

GET /<Location>

This endpoint is needed for the AutoComplete feature in the Search component. It interacts with Google Maps API and uses a location partial to query for predictions.

{
  predictions: [
    {
      description: "San Francisco, CA, United States",
      id: "1b9ea3c094d3ac23c9a3afa8cd4d8a41f05de50a",
      matched_substrings: [ ... ],
    ,
    types: ["locality", "political", "geocode"]
    ...
  ]
}

beer.ly's People

Contributors

ntoung avatar rewhsu avatar michaelmerrilltest avatar woobianca avatar kkwokwai22 avatar rdubs avatar jlsha avatar

Watchers

James Cloos avatar  avatar

beer.ly's Issues

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.