strongloop/loopback-example-access-control — pull request #5 by bajtos (2014-01-03 19:27:33+00:00)
Title: RFC: dynamic model resources in Angular [DO NOT MERGE]

The pull request contains a spike implementation of module that can dynamically generate Angular $resource services for all Models exposed in a LoopBack app.

The solutions has several parts:

#### 1. Server-side module

server/lib/angular-resources.client.js
server/lib/angular-resources.js

This module provides a middleware (request handler) that returns
Angular module defining $resource objects for all public models
defined in the loopback application.

It should be probably extracted to a new module, e.g. loopback-angular.

#### 2. Server-side integration

One-liner in server/app.js to install the middleware defined above.

#### 3. Client-side changes

Replace 'client/js/services.js' with the script provided by the new
middleware, rename 'starter.services' to 'lbModels' in depedency
configurations.

/to: @ritch @Schoonology @seanbrookes
/cc: @raymondfeng @altsang