Sha256: 13740664b162c42d5946daf30276cd4f3cfaf029e3518073e51698d68b8fa80b

Contents?: true

Size: 1.33 KB

Versions: 12

Compression:

Stored size: 1.33 KB

Contents

<!DOCTYPE html>
<html>
<head>
  <title><%= yield(:title) %></title>

  <script src="//cdn.shopify.com/s/assets/external/app.js?<%= Time.now.strftime('%Y%m%d%H') %>"></script>
  <script type="text/javascript">
    // Initialise the Shopify App.
    ShopifyApp.init({
      "apiKey": "<%= ShopifyApp.configuration.api_key %>",
      "shopOrigin": "<%= "https://#{ @shop_session.url }" if @shop_session %>",
      "debug": <%= Rails.env.development? ? 'true' : 'false' %>
    });
  </script>

  <%= stylesheet_link_tag 'application', media: 'all', 'data-turbolinks-track' => true %>

  <%= csrf_meta_tags %>

  <%= yield :extra_head %>
</head>
<body>
  <script type="text/javascript">
    ShopifyApp.Bar.initialize({
      title: "<%= yield(:title) %>",
      icon: "<%= image_url("disco_app/icon.svg") %>",
      buttons: <%= content_for?(:buttons) ? content_for(:buttons) : '{}' %>,
      breadcrumb: <%= content_for?(:breadcrumb) ? content_for(:breadcrumb) : 'undefined' %>
    });
  </script>

  <%= yield %>

  <% flash.each do |key, message| %>
  <script type="text/javascript">
    ShopifyApp.flash<%= (key == 'error') ? 'Error' : 'Notice' %>('<%= message %>');
  </script>
  <% end %>

  <%= javascript_include_tag 'application', 'data-turbolinks-track' => true, 'data-turbolinks-eval' => false %>

  <%= render 'disco_app/shared/icons' %>
</body>
</html>

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
disco_app-0.9.6 app/views/layouts/embedded_app.html.erb
disco_app-0.9.7 app/views/layouts/embedded_app.html.erb
disco_app-0.9.8 app/views/layouts/embedded_app.html.erb
disco_app-0.9.9 app/views/layouts/embedded_app.html.erb
disco_app-0.9.10 app/views/layouts/embedded_app.html.erb
disco_app-0.9.11 app/views/layouts/embedded_app.html.erb
disco_app-0.10.0 app/views/layouts/embedded_app.html.erb
disco_app-0.10.1 app/views/layouts/embedded_app.html.erb
disco_app-0.10.2 app/views/layouts/embedded_app.html.erb
disco_app-0.10.3 app/views/layouts/embedded_app.html.erb
disco_app-0.10.4 app/views/layouts/embedded_app.html.erb
disco_app-0.10.5 app/views/layouts/embedded_app.html.erb