Larry Siden
2014-Feb-03 03:52 UTC
Need a way for Rails controller to return flash messages in response to AJAX request
This post should explain what I'm trying to do. https://stackoverflow.com/questions/21515183/need-a-way-for-rails-controller-to-return-flash-messages-in-response-to-ajax-req?noredirect=1#comment32487494_21515183 I have already developed a workaround I'm not entirely pleased with but which I believe with some work and help from the community may be a candidate to become part of Rails if a better solution cannot be found. My road-map for now is to first isolate my solution into it's own gem and release it. If it receives a positive response, I'll attempt to integrate it into the Rails project and submit a pull request. I am an experienced developer but fairly new to Rails (but learning fast!). I have tested this solution in my own application but know that some work and a reliable suite of tests will probably be required before it might be acceptable as a candidate for integration into Rails. Before I go to this effort, I'd like to know a couple things: 1) The solution contains some Coffescript (Javascript). While Rails has great support for automated testing of models and controllers, I have not been able to find a standard facility for testing Javascript. While I can certainly adapt and use some framework for testing (or develop my own), I would like to use one that is already widely accepted by the Rails community and most importantly by the committers who review submissions. What is the current best practice for testing Javascript as part of Rails? 2) Are there any guidelines I will need to follow in order for a patch or pull-request to be considered that are not already listed in http://guides.rubyonrails.org/contributing_to_ruby_on_rails.html. Is this guide up-to-date or is there another document that is more definitive. 3) Are improvements submitted as pull-requests from my own clone of Rails, or as patch files? (If the latter, please read my use of "pull-request" as "patch". :) Thank you all! Rails is the best web framework I have ever used and the smartest developers seem to be using Ruby. I want to contribute. -Larry -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-core+unsubscribe@googlegroups.com. To post to this group, send email to rubyonrails-core@googlegroups.com. Visit this group at http://groups.google.com/group/rubyonrails-core. For more options, visit https://groups.google.com/groups/opt_out.