Skip to content

Instantly share code, notes, and snippets.

@kelvinj
Forked from JeffreyWay/challenge.md
Created April 24, 2013 15:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kelvinj/5453196 to your computer and use it in GitHub Desktop.
Save kelvinj/5453196 to your computer and use it in GitHub Desktop.

Challenge: you need a flexible (swap in other repository implementations) way to display some kind of resource. Let's say, Posts. What does your folder structure look like?

Requirements:

  • Repository implements an interface
  • Must show at least one implementation of the interface (Eloquent version is fine)
  • The interface is injected into your PostsController.
  • Show where you register your IoC bindings
  • Show folder structure. Where are interfaces/repositories stored?
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment