Skip to content

Production env broken under sprockets-rails >= 3 (Rails 5) #170

@thewoolleyman

Description

@thewoolleyman

(Similar to issue as rails/sprockets-rails#237)

I'm running Rails 5 beta, and found this issue.

When running in Rails production env with config.assets.compile = false, the react_component call in a view blows up. The root cause is because the following line blows up due to Rails.application.assets being nil:

https://github.com/shakacode/react_on_rails/blob/009db0d/lib/react_on_rails/server_rendering_pool.rb#L79

This is apparently new behavior in Sprockets 3 (see link to sprockets-rails issue above), which is why the example app (which uses sprockets-rails 2/Rails 4) still works.

Thanks,
-- Chad

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions