From 630b321e71f18acae012da9d928c7c6a3bf26758 Mon Sep 17 00:00:00 2001 From: pvincent Date: Fri, 2 Jun 2023 23:27:33 +0400 Subject: [PATCH] lambda --- app/views/layouts/_navbar.html.erb | 23 ++++++++--------------- app/views/layouts/application.html.erb | 2 +- app/views/main/about.html.erb | 3 ++- app/views/main/home.html.erb | 6 +++--- config/environments/development.rb | 18 +++++++++--------- 5 files changed, 23 insertions(+), 29 deletions(-) diff --git a/app/views/layouts/_navbar.html.erb b/app/views/layouts/_navbar.html.erb index 8f85d0c..1432ba3 100644 --- a/app/views/layouts/_navbar.html.erb +++ b/app/views/layouts/_navbar.html.erb @@ -50,29 +50,22 @@ Dashboard - - -
  • - TeamHome
  • - +
  • + ProjectsAbout
  • + diff --git a/app/views/layouts/application.html.erb b/app/views/layouts/application.html.erb index 7485d66..0cd8551 100644 --- a/app/views/layouts/application.html.erb +++ b/app/views/layouts/application.html.erb @@ -9,7 +9,7 @@ <%= stylesheet_link_tag "application", "data-turbo-track": "reload" %> <%= javascript_importmap_tags %> - + <%= render 'layouts/navbar' %>
    <%= yield %> diff --git a/app/views/main/about.html.erb b/app/views/main/about.html.erb index 453a293..e3706c4 100644 --- a/app/views/main/about.html.erb +++ b/app/views/main/about.html.erb @@ -1,5 +1,6 @@ +

    About page

    -

    Main#index

    +

    Main#index

    aaaaaaaaaaaaaa

    aaaaaasaaa

    Find me in app/views/main/index.html.erb

    diff --git a/app/views/main/home.html.erb b/app/views/main/home.html.erb index be65b21..3399827 100644 --- a/app/views/main/home.html.erb +++ b/app/views/main/home.html.erb @@ -1,9 +1,9 @@

    HOME

    -
    - this is a welcome message. +
    + Hello man
    -
    +
    Lorem ipsum dolor sit amet, consectetur adipisicing elit. Aspernatur provident dolor quod laboriosam facere quas, excepturi quasi consequuntur quo pariatur recusandae, eaque doloremque voluptas, a commodi officia ducimus animi incidunt.
    diff --git a/config/environments/development.rb b/config/environments/development.rb index 5aabc41..a416d0f 100644 --- a/config/environments/development.rb +++ b/config/environments/development.rb @@ -1,4 +1,4 @@ -require "active_support/core_ext/integer/time" +require 'active_support/core_ext/integer/time' Rails.application.configure do # Settings specified here will take precedence over those in config/application.rb. @@ -19,13 +19,13 @@ Rails.application.configure do # Enable/disable caching. By default caching is disabled. # Run rails dev:cache to toggle caching. - if Rails.root.join("tmp/caching-dev.txt").exist? + if Rails.root.join('tmp/caching-dev.txt').exist? config.action_controller.perform_caching = true config.action_controller.enable_fragment_cache_logging = true config.cache_store = :memory_store config.public_file_server.headers = { - "Cache-Control" => "public, max-age=#{2.days.to_i}", + 'Cache-Control' => "public, max-age=#{2.days.to_i}" } else config.action_controller.perform_caching = false @@ -72,14 +72,14 @@ Rails.application.configure do config.semantic_logger.add_appender( io: $stdout, formatter: BasicFormatter.new, - filter: ->log { - if log.name == "ActionView::Base" - log.message&.exclude?("Rendered /") && log.message.exclude?("Rendered layout /") - elsif log.name == "Rails" && log.message != nil - log.message.exclude?("Started GET \"/rails/live/reload") + filter: lambda { |log| + if log.name == 'ActionView::Base' + log.message&.exclude?('Rendered /') && log.message&.exclude?('Rendered layout /') + elsif log.name == 'Rails' && !log.message.nil? + log.message.exclude?('Started GET "/rails/live/reload') else true end - }, + } ) end