Skip to content

Commit

Permalink
loads css in a standard way to prevents side effects
Browse files Browse the repository at this point in the history
  • Loading branch information
adrienpoly committed Feb 2, 2018
1 parent 81e751a commit 29e8ae2
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions app/views/layouts/application.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,8 @@
<html>
<head>
<title>A modest TodoMVC rails app boosted with Stimulus</title>
<% if Rails.env.production? %>
<style>
<%= raw File.read("public" + asset_pack_path("application.css")) %>
</style>
<% else %>
<%= stylesheet_pack_tag 'application', media: 'all', 'data-turbolinks-track': 'reload' %>
<% end %>

<%= stylesheet_pack_tag 'application', media: 'all', 'data-turbolinks-track': 'reload' %>
<%= javascript_pack_tag 'application', 'data-turbolinks-track': 'reload', async: Rails.env.production? %>
<meta name=viewport content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
Expand Down

0 comments on commit 29e8ae2

Please sign in to comment.