Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: No inline style option for ReactOnRailsHelper#react_component #173

Closed
tangrufus opened this issue Dec 29, 2015 · 5 comments

Comments

@tangrufus
Copy link
Contributor

Feature request:
Add a no inline style option to ReactOnRailsHelper#react_component to skip style: "display:none"

Reason:
Eliminate the needs of unsafe-line for Content Security Policy

Related file:

@justin808
Copy link
Member

Why are display:none lines unsafe?

@tangrufus Would you like to create a PR for this? The option could be "skip_display_none", with a default of false.

I'd like to get some community feedback on the option name. Do we need a CSS style for "js-react-on-rails-component" for "display:none"?

2015-12-29_11-26-16

@tangrufus
Copy link
Contributor Author

display:none lines are safe.

However, if style-src: 'unsafe-inline' are included in content security policy headers, browsers would execute all inline styles from any source. Somebody could hijack the web page.

PR created. Thanks!

@justin808
Copy link
Member

See #174. We need to get tests included and we can add this.

@justin808
Copy link
Member

@tangrufus Any updates?

@aaronvb
Copy link
Member

aaronvb commented Jan 30, 2016

@justin808 @tangrufus Closing this. See #218

@aaronvb aaronvb closed this as completed Jan 30, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants