Giter Site home page Giter Site logo

mapbox-react's Introduction

MapBox Tutorial

This project was made to adapt a tutorial on MapBox into a React/Redux context. MapBox has a lot of helpful resources for using the API, but not much in regards to React and Redux. This project React-ifies one of those tutorials. The app uses some sample GeoJson Data to make a store locator that allows the user to interact with the map and a list of locations.

Original Tutorial

And just for fun, I dockerized it and deployed the project to Amazon's Elastic Container Service.

The deployed application can be viewed at: AWS ECS Deployment

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

git
npm

(optional)

docker

Installing

$ git clone [email protected]:jsullivan5/mapbox.git

$ npm install

Start Dev Server:

$ npm start

Or

$ docker build -t sample-app .
$ docker run -it \
  -v ${PWD}:/usr/src/app \
  -v /usr/src/app/node_modules \
  -p 3000:3000 \
  --rm sample-app

Stop by killing the dev server

Or

$ docker-compose up -d --build

To Stop

$ docker-compose stop

Running the tests

$ npm test

Break down into end to end tests

Unit test done with Jest. As of now, actions and reducers are the only things being tested. More coming soon...

Deployment

For an optimized production build:

$ npm build

Or for an optimized production Docker image:

$ docker build -f Dockerfile-prod -t map-box-prod .

Spin up the container:

$ docker run -it -p 80:80 --rm map-box-prod

Or

$ docker-compose -f docker-compose-prod.yml up -d --build

Built With

Screen Shots

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.