trix
trix copied to clipboard
Not compatible with Rails 5.2 CSP
Issue When trying to implement CSP(content security policy) in Rails 5.2 Trix editor breaks. can anyone help here with how to fix it?
Code added in application.rb
config.content_security_policy do |policy|
policy.default_src :self, :https
policy.font_src :self, :https, :data
policy.img_src :self, :https, :data
policy.object_src :none
policy.script_src :self, :https
policy.style_src :self, :https
end
rendered editor:-
Environment (please complete the following information):
- Rails version: 5.2.4
- trix-rails version: 2.3.0
- Browser: