Documentation
Search…
View a Ruby on Rails Project in the Web-Browser Tab
Ruby on Rails websites by default cannot be displayed in an IFrame. Since the Web-Browser tab displays the page in an IFrame, it will show an error when trying to visit a Rails website. You can get around this error by opening App/config/application.rb and adding the following config inside the class:
1
config.action_dispatch.default_headers = {
2
'X-Frame-Options' => 'ALLOWALL'
3
}
Copied!
Then restart the Rails server and it should now be able to be displayed in the Web Browser tab!
Copy link