Skip to content

Commit

Permalink
added vue and created teams_ctrl.js
Browse files Browse the repository at this point in the history
  • Loading branch information
rymcmahon committed Sep 20, 2016
1 parent 69f6eb4 commit 69871f8
Show file tree
Hide file tree
Showing 10 changed files with 10,096 additions and 3 deletions.
Binary file added .DS_Store
Binary file not shown.
2 changes: 1 addition & 1 deletion app/assets/javascripts/application.js
Expand Up @@ -12,5 +12,5 @@
//
//= require jquery
//= require jquery_ujs
//= require turbolinks
//= require vue
//= require_tree .
6 changes: 6 additions & 0 deletions app/assets/javascripts/teams_ctrl.js
@@ -0,0 +1,6 @@
new Vue({
el: '#new-team-form',
data: {
message: 'Hello Vue.js!'
}
})
4 changes: 4 additions & 0 deletions app/controllers/api/v1/teams_controller.rb
@@ -0,0 +1,4 @@
class Api::V1::TeamsController < ApplicationController
def create
end
end
3 changes: 1 addition & 2 deletions app/views/layouts/application.html.erb
Expand Up @@ -3,12 +3,11 @@
<head>
<title>VueRailsNestedForms</title>
<%= csrf_meta_tags %>
<%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track': 'reload' %>
<%= javascript_include_tag 'application', 'data-turbolinks-track': 'reload' %>
</head>

<body>
<%= yield %>
<%= javascript_include_tag 'application', 'data-turbolinks-track': 'reload' %>
</body>
</html>
5 changes: 5 additions & 0 deletions app/views/teams/new.html.erb
@@ -0,0 +1,5 @@
<div id="new-team-form">
<p>
{{ message }}
</p>
</div>
6 changes: 6 additions & 0 deletions config/routes.rb
@@ -1,3 +1,9 @@
Rails.application.routes.draw do
# For details on the DSL available within this file, see http://guides.rubyonrails.org/routing.html
resources :teams
namespace :api do
namespace :v1 do

end
end
end
Binary file added vendor/.DS_Store
Binary file not shown.
Binary file added vendor/assets/.DS_Store
Binary file not shown.

0 comments on commit 69871f8

Please sign in to comment.