GithubHelp home page GithubHelp logo

meetarang's People

Contributors

locnguyen avatar vietqle avatar

Watchers

 avatar

Forkers

vietqle

meetarang's Issues

As a organizer, I can see a dashboard page

The dashboard should list all the meetups that I am an organizer of with some related statistics.

See this page for documentation on the API endpoint to use: http://www.meetup.com/meetup_api/docs/members/:member_id#get

A sample request to the Meetup API is:

https://api.meetup.com/members/self?photo-host=public&fields=memberships&page=20

To get this done:

  1. Set up a new UI-Router state in our Angular app at /dashboard where the data can be rendered.
  2. Create a proxy endpoint in our API at /api/dashboard that will make the call to the Meetup API.

Need to load external configuration file

It's bad practice to track sensitive configurations in a Git repo. We need to externalize them to a JSON configuration file that is located somewhere else, like in a hidden directory in the current user's home directory.

Need session management in UI

A Session service is needed to manage a user's authentication state.

Session#create - tricky as we are depending on the Meetup Oauth2 provider to authenticate ourselves. The end result should be persisting the JWT and user object to a cookie

Session#isLoggedIn - return true if the cookie value exists

Session#getUser - returns the user object for the user who is logged in

Session#refresh - calls the proxy to get a new JWT to update our cookie with

Session#destroy - clear out the cookie value

Add a gulpfile

Since webpack is really meant to be used for bundling code for bundling we still need a task runner for things like listing, running tests etc.

As an organizer, I can login using my Meetup account

Will need to authenticate organizers using Meetup as the Oauth2 provider. See the documentation for details.

  • The ui-router state should make the login form reachable at /login
    • Add form validation with ngMessages
    • Successful login should dump the user on a stubbed out homepage at /home
  • Build the proxy layer endpoint to integrate with Meetup's Oauth2 API

Add a logging library

Bunyan is a great tool and I like its JSON formatted output.

  • Set up a generic logger in its own module in the api/ directory. Any one who wants to use it can require('./logger')
  • Set up a child logger for each HTTP request so that each child has a correlation ID associated with the request. This makes it easy to tie back a log line(s) back to a particular HTTP request.
  • The output directory should be configurable. For NODE_ENV=development we can keep it simple and output to the current working directory.
  • Update README with instructions on how to tail the log file so its output is human friendly

Add a Meetup API proxy

We need a Hapi proxy that can take the JWT from the header, decode it, and replace that header with the decoded access_token that the Meetup API expects.

Create a lightweight API layer to proxy Meetup API calls

Let's use HapiJS to build our API layer since I have a lot of experience with it already and can iterate much quicker.

  • Since the client side code is in app/ let's put the proxy code under api/index.js
  • Add nodemon as a dependency
  • Add an npm script so we can start the API easily. npm run api should run NODE_ENV=development nodemon api
  • Add add-module-path as a dependency. This makes the require function calls at the top of every file a lot cleaner

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.