Skip to content

Instantly share code, notes, and snippets.

@evan-007
Created May 16, 2014 12:38
Show Gist options
  • Save evan-007/3637b27dbc28952b06bf to your computer and use it in GitHub Desktop.
Save evan-007/3637b27dbc28952b06bf to your computer and use it in GitHub Desktop.
Angular on Rails book possible issues
page 34:
refactoring into a partial isn't explicitly mentioned. Maybe mention that if you just drop the block on page 34 into the existing ```dashboard.html```, then the submit button needs to have params passed into it:
<input type="submit" class="btn btn-sm btn-primary" ng-click="showShareBox=!showShareBox;share(recipient, article)"
ng-disabled="shareForm.$invalid" value="Share">
Page 36
Earlier in the book, the routes namespace resources :shares under :api. The controller needs to be created in app/controllers/api/shares_controller.rb, right? Otherwise throws uninitialized constant API error. FYI, sample app does not namespace this controller/route, contrary to the book.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment