Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Dylan Clark
    @dylnclrk
    @gazay do you know how far back Rails 4 support goes? It wasn't specifically enumerated in any of the release notes as far as I could see. And it seems like there's been a bit of churn in the issues (mostly people complaining and then not providing any clarifications).
    thanks!
    Alexey Gaziev
    @gazay
    Hello! I can't reproduce those issues in new applications. And I know many people who using gon on last rails versions and all works as expected. If anyone could provide example of not working functionality ā€“ I'll try to fix it, but as far as I get those issues I have very small reproduction steps. So I just do some little refactorings now and I have issue with controller tests with example of not working application ā€“ I'll try to fix it next time I have time. Do you have any ideas what is wrong with gon-rails4 behavior? I really want to help
    seaify
    @seaify
    how can i use gon in rails app with assets pipeline?
    Roman Myronov
    @Shamash2014
    Which rails version?
    LeoDaoTao
    @LeoDaoTao
    Iā€™m having issues using gon with Rails 4.2.4. It seems I do not get variables from my controller on first page load. I have to refresh the page to get them. Is there an obvious reason for that? The gon variable just does not exist when I try to access it in the console. It works after a refresh like a charm.
    LeoDaoTao
    @LeoDaoTao
    Moved Gon::Base.render_data before the closing body tag and it is working. If anyone has a different solution I would like to see it as well. Also, my Turbolinks are off as well.
    Yaniv Ran
    @YanivRan
    Just thought that I'll point out that gon.watch doesn't work with namespaces. I don't know what it takes to fix it, but it currently doesn't work when you supply a namespace for your variables..
    Filip Bartuzi
    @Bartuz
    hello
    Punita Ojha
    @punitaojha
    This message was deleted
    Lioxor64
    @lioxor64

    Hello, my name is Liora and I am currently hunting open source projects for company NeuraLegion (www.neuralegion.com)
    We just launched a free annual subscription for open source projects for our AIAST tool NexPloit.

    If you are interested, please, reach us on opensource@neuralegion.com!

    Thank you for your time and consideration! If you have any questions, please do not hesitate to contact us!

    Best!

    Matt McFarland
    @McFarFr_twitter
    Good morning!

    I'm using gon in a web application where we're initializing gon with a bunch of data displayed generally across the application. Once piece of data we're initializing is a list of users. These users have names that are input from the users themselves, so the input is "unsafe". I see here that gon is calling html_safe when it renders the data we pass it.

    Is there a way for me to override the default rendering method? I'd like to call ActiveSupport's json_escape method to make sure I'm escaping any nefarious user input for a user's name. https://github.com/rails/rails/blob/master/activesupport/lib/active_support/core_ext/string/output_safety.rb#L306 Any thoughts?

    Matt McFarland
    @McFarFr_twitter
    After playing around with a bunch of options today, I think the answer to my question actually lies in changing the options used in Gon's JsonDumper. https://github.com/gazay/gon/blob/master/lib/gon/json_dumper.rb#L5
    Matt McFarland
    @McFarFr_twitter
    I fixed my issue by overrides the options passed to JsonDumper. We needed to pass mode: :rails, escape_mode: :unicode_xss