-
Notifications
You must be signed in to change notification settings - Fork 178
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
No Page Content Showing #252
Comments
Can you show the contents of the |
I won't be at a computer for a day or so but it's basically just the web
console code, nothing else (headers and footers and layout all gone, very
bizzare!)
…On Fri, 9 Feb 2018 at 21:00, Genadi Samokovarov ***@***.***> wrote:
Can you show the contents of the View Source Page option from your
browser? Since the web-console augments your page with it'\s own
HTML/CSS/JS content, if you have unclosed tags before, that may interfere
with your content.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#252 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA4l6qCcPIFkWVGw54AWSfQ6AkwTVAavks5tTBcjgaJpZM4R_ZV2>
.
|
|
If I remove the |
I encounted same problem too. I think this issue reason is implementation changed from I don't know what expected type of temporary workaround the following seems to work fine. def write(content)
raw_body_obj = Array(body).first
if raw_body_obj.respond_to?(:body)
raw_body = raw_body_obj.body
else
raw_body = raw_body_obj.to_s
end
if position = raw_body.rindex('</body>')
raw_body.insert(position, content)
else
raw_body << content
end
self.body = raw_body
end |
@siman-man can you reproduce this in a simple rails app or give a bit more context about your experience with this issue? |
I found the cause of this issue. (In my case)
I created a new Rails app (scaffold user), and set class ApplicationController < ActionController::Base
protect_from_forgery with: :exception
before_action :expires_now
end In this state without with |
@siman-man is the |
This is my Gemfilesource 'https://rubygems.org'
git_source(:github) do |repo_name|
repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/")
"https://github.com/#{repo_name}.git"
end
# Bundle edge Rails instead: gem 'rails', github: 'rails/rails'
gem 'rails', '~> 5.1.6'
# Use mysql as the database for Active Record
gem 'mysql2', '>= 0.3.18', '< 0.6.0'
# Use Puma as the app server
gem 'puma', '~> 3.7'
# Use SCSS for stylesheets
gem 'sass-rails', '~> 5.0'
# Use Uglifier as compressor for JavaScript assets
gem 'uglifier', '>= 1.3.0'
# See https://github.com/rails/execjs#readme for more supported runtimes
# gem 'therubyracer', platforms: :ruby
# Use CoffeeScript for .coffee assets and views
gem 'coffee-rails', '~> 4.2'
# Turbolinks makes navigating your web application faster. Read more: https://github.com/turbolinks/turbolinks
gem 'turbolinks', '~> 5'
# Build JSON APIs with ease. Read more: https://github.com/rails/jbuilder
gem 'jbuilder', '~> 2.5'
# Use Redis adapter to run Action Cable in production
# gem 'redis', '~> 4.0'
# Use ActiveModel has_secure_password
# gem 'bcrypt', '~> 3.1.7'
# Use Capistrano for deployment
# gem 'capistrano-rails', group: :development
group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
# Adds support for Capybara system testing and selenium driver
gem 'capybara', '~> 2.13'
gem 'selenium-webdriver'
end
group :development do
# Access an IRB console on exception pages or by using <%= console %> anywhere in the code.
gem 'web-console', '>= 3.3.0'
gem 'listen', '>= 3.0.5', '< 3.2'
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
gem 'spring'
gem 'spring-watcher-listen', '~> 2.0.0'
end
# Windows does not include zoneinfo files, so bundle the tzinfo-data gem
gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw, :jruby] Gemfile.lock
|
@siman-man thanks for the hints, I was able to reproduce the issue and fix it. Will release |
@gsamokovarov thanks! I confirmed this issue solved in master branch. I'm look forward to 3.6.1 release. 😄 |
I cannot be sure that every body can be coerced as an array, the only thing we can rely on is that all the bodies will respond to each. This fixes rails#252.
I'm working on a rails project and I'm stumped, the web console shows up when I attempt to manually include it using <% console %> but the page content disappears, I've been googling around and haven't had any luck.
This is what the result looks like: https://i.imgur.com/WSVdXuf.png
My Gemfile: https://gist.github.com/anonymous/d2dc9e7c5438acfcb4ff2746b71a711b
The text was updated successfully, but these errors were encountered: