For example, we have a format called "iphone", which we use to render mobile-optimized views using the same controllers as their html counterparts. This PR makes the format/extension explicit so that analytical can be called safely from any page/format.
This pull request fails (merged 083b4d4 into bf83549).
I believe the @travisbot failure is because master is already failing. Please let me know if I've mistaken.
Keep explicit format but remove .erb handler because passing handlers…
… as extensions is deprecated in rails 3.2.
This pull request fails (merged 9fbadf8 into bf83549).
Pass in format and handler as hash keys for rails 4 compatibility.
This pull request fails (merged 989174e into bf83549).
@jkrall Can I get your input on this PR? The reason it's useful to specify the html format explicitly is that it allows the partial to be called from parent pages whose format is different. For example, one might have a :ipad or :iphone format that renders :html, and this allows them to do that without creating an entirely separate partial from the one bundled inside the gem.
@freerobby Unfortunately, I haven't had any time to work on this gem in a while... sorry for the crappy slow response :(
This looks fine to me, but I don't have time right now to pull it and test in each version of rails to make sure that it doesn't have some weird side-effect. Have you tested in rails 2.3 and 3.x?
(btw, if you have any interest in picking up maintenance of analytical, or helping out... let me know. I'm swamped with work, so I'd welcome any assistance.)
@jkrall This was tested on rails 2.3 and 3.2.
I don't have time to be an official maintainer either, but I'm happy to help out (go through PRs from time to time, test them on rails 2.3/3.1/3.2, merge/comment accordingly) if you'd like.
@freerobby Offer accepted!
I just added you as a collaborator, feel free to merge & ship this pull-request if you feel comfortable with it.
Would be nice to fix up the broken tests, so that Travis could be working for us... but I haven't had time unfortunately :(
(Also, let me know if you ever want me to remove you from the repo...)