Answer the question
In order to leave comments, you need to log in
How to pass data from rails to angular?
Hello, I want to understand the issue of implementing angular in rails. While I want to create a simple table filter. But I don't understand how to pass data to the front-end. Help with advice or throw off the necessary literature please.
update
<% @users.each do |user| %>
<tr>
<td><%= user.name %></td>
<td><%= user.age %></td>
<% end %>
def new
@user = current_doctor.users.new
end
Answer the question
In order to leave comments, you need to log in
angular separately - rails separately, rest/http api in between.
And for this you are trying to shove angular there? I think you're choosing the wrong tool.
Good afternoon.
Just give the data in the controller in json
Example at the link: https://github.com/kunashir/requitement/blob/maste...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question