Merge pull request #29897 from kirs/frozen-actionview

Use frozen string literal in actionview/
This commit is contained in:
Rafael França 2017-07-24 15:54:08 -04:00 committed by GitHub
commit 9c35bf2a6a
178 changed files with 354 additions and 1 deletions

View File

@ -93,6 +93,10 @@ Style/FrozenStringLiteralComment:
- 'activejob/**/*'
- 'activerecord/**/*'
- 'actionmailer/**/*'
- 'actionview/**/*'
Exclude:
- 'actionview/test/**/*.builder'
- 'actionview/test/**/*.ruby'
# Use `foo {}` not `foo{}`.
Layout/SpaceBeforeBlockBraces:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "rake/testtask"
require "fileutils"
require "open3"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
version = File.read(File.expand_path("../RAILS_VERSION", __dir__)).strip
Gem::Specification.new do |s|

View File

@ -1,4 +1,5 @@
#!/usr/bin/env ruby
# frozen_string_literal: true
COMPONENT_ROOT = File.expand_path("..", __dir__)
require_relative "../../tools/test"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
#--
# Copyright (c) 2004-2017 David Heinemeier Hansson
#

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/module/attr_internal"
require "active_support/core_ext/module/attribute_accessors"
require "active_support/ordered_options"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/string/output_safety"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module CompiledTemplates #:nodoc:
# holds compiled template code

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "concurrent/map"
require_relative "path_set"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "concurrent/map"
require_relative "dependency_tracker"
require "monitor"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/string/output_safety"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
# Returns the version of the currently loaded Action View as a <tt>Gem::Version</tt>
def self.gem_version

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/benchmarkable"
module ActionView #:nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/module/attribute_accessors"
require "active_support/core_ext/enumerable"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/array/extract_options"
require "active_support/core_ext/hash/keys"
require_relative "asset_url_helper"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "zlib"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "set"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
# = Action View Cache Helper
module Helpers

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/string/output_safety"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/module/attr_internal"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
# = Action View CSRF Helper
module Helpers

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "date"
require_relative "tag_helper"
require "active_support/core_ext/array/extract_options"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
# = Action View Debug Helper
#

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "cgi"
require_relative "date_helper"
require_relative "tag_helper"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "cgi"
require "erb"
require_relative "form_helper"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "cgi"
require_relative "tag_helper"
require "active_support/core_ext/string/output_safety"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "tag_helper"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/hash/keys"
require "active_support/core_ext/string/output_safety"
require "active_support/number_helper"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/string/output_safety"
module ActionView #:nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module RecordTagHelper

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
# = Action View Rendering

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/object/try"
require "rails-html-sanitizer"

View File

@ -1,4 +1,4 @@
# frozen-string-literal: true
# frozen_string_literal: true
require "active_support/core_ext/string/output_safety"
require "set"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags #:nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "checkable"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "collection_helpers"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "collection_helpers"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/time/calculations"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "checkable"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "placeholderable"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "placeholderable"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Helpers
module Tags # :nodoc:

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/string/filters"
require "active_support/core_ext/array/extract_options"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "tag_helper"
require "active_support/core_ext/string/access"
require "i18n/exceptions"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "javascript_helper"
require "active_support/core_ext/array/access"
require "active_support/core_ext/hash/keys"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "rendering"
require "active_support/core_ext/module/remove_method"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "concurrent/map"
require "active_support/core_ext/module/remove_method"
require "active_support/core_ext/module/attribute_accessors"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module ModelNaming #:nodoc:
# Converts the given object to an ActiveModel compliant one.

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView #:nodoc:
# = Action View PathSet
#

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "action_view"
require "rails"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/module"
require_relative "model_naming"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
# This class defines the interface for a renderer. Each class that
# subclasses +AbstractRenderer+ is used by the base +Renderer+ class to

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "concurrent/map"
require_relative "partial_renderer/collection_caching"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module CollectionCaching # :nodoc:
extend ActiveSupport::Concern

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
# This is the main entry point for rendering. It basically delegates
# to other objects like TemplateRenderer and PartialRenderer which

View File

@ -1,4 +1,5 @@
# frozen_string_literal: true
require "fiber"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/object/try"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require_relative "view_paths"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "action_dispatch/routing/polymorphic_routes"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
namespace :cache_digests do
desc "Lookup nested dependencies for TEMPLATE (like messages/show or comments/_comment.html)"
task nested_dependencies: :environment do

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/enumerable"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView #:nodoc:
# = Action View Template Handlers
class Template

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Template::Handlers
class Builder

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
class Template
module Handlers

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
::ActiveSupport::Deprecation.warn("ActionView::Template::Handlers::Erubis is deprecated and will be removed from Rails 5.2. Switch to ActionView::Template::Handlers::ERB::Erubi instead.")
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "erubi"
module ActionView

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
gem "erubis"
require "erubis"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Template::Handlers
class Html < Raw

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView
module Template::Handlers
class Raw

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView #:nodoc:
# = Action View HTML Template
class Template

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "pathname"
require "active_support/core_ext/class"
require "active_support/core_ext/module/attribute_accessors"

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
module ActionView #:nodoc:
# = Action View Text Template
class Template

View File

@ -1,3 +1,5 @@
# frozen_string_literal: true
require "active_support/core_ext/module/attribute_accessors"
module ActionView

Some files were not shown because too many files have changed in this diff Show More