Coder Social home page Coder Social logo

codein / food_truck Goto Github PK

View Code? Open in Web Editor NEW
0.0 2.0 0.0 1.84 MB

a service that tells the user what types of food trucks might be found near a specific location on a map.

License: MIT License

CoffeeScript 27.88% CSS 3.18% Python 28.32% JavaScript 38.99% Shell 1.63%

food_truck's Introduction

food_truck

A service that tells the user what types of food trucks might be found near a specific location on a map. A demo version is hosted at http://146.148.41.202:8887/static/index.html

Overview

  • Features
  • Codebase overview
  • Setup
    • Data loading.
    • Starting server.
    • Running unitest.
  • Development
  • Improvements

Features

  • A the landing page the user two option to find food trucks in a specific location

    1. The user could directly click on a location on the map.
    2. The user can choose to click on one of the suggested locations. (for ex. "Financial District") In both the scenarios, the app will behave as follows Firstly, zoom down to the location. Secondly, drop markers for food trucks found around that area. Finally will render records for each food truck in the left search result listings section.
  • Markers have alphabetically label to correspond to records in the listing sections.

  • Clicking on the address on the record in the listing section, will animate it's coresponding marker.

Codebase overview

The codebase mainly consists of

  • App code in src\app.coffee and index.html
  • Server code in server.py and it's unitest in api_test.py
  • Finally the code data\data_engineering.py and data\sql_orm.py that is used to transform/engineer the data and load it into mysql sqlAlchamey ORM.

Setup

  • the setup involves primarily going through ./setup.sh

    • Data loading.
        # setup db
        python data/sql_orm.py
        # load data
        cd data
        python data_engineering.py
    
    • Starting server.
    ./run_server.sh
    
    • Running unitest.
    ./test_runnner.sh
    

Development

Grunt is used to compiling src\app.coffee into js/index.js

grunt watch

on saving a .coffee file grunt compiles coffescript into javascript.

Improvements

  • Implement paging of query results
  • Ansible scriptsfor automation around setup
  • User should be able to control the serach radius around a user specified location.
  • Identify and remove duplicate food trucks in same location with the same ownership.
  • use grunt to minify the compiled js.
  • Add ability to narrow down to a location using a search inplimentation.
  • use nginx to load balance
  • use redis to cache results

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.