houdini/app/views/layouts/_javascripts.html.erb
2020-04-23 14:09:56 -05:00

36 lines
971 B
Text

<%- # License: AGPL-3.0-or-later WITH Web-Template-Output-Additional-Permission-3.0-or-later -%>
<!-- Load up polyfill service -->
<script src="https://cdn.polyfill.io/v1/polyfill.min.js"></script>
<%= render 'layouts/app_data' %>
<% if Settings.payment_provider.stripe_proprietary_v2_js %>
<script type="text/javascript" src="https://js.stripe.com/v2/"></script>
<% else %>
<%= javascript_pack_tag "page__stripe_wrapper" %>
<% end %>
<script>
Stripe.setPublishableKey("<%= Settings.payment_provider.stripe_public_key %>");
window._csrf = "<%= form_authenticity_token %>";
</script>
<%= yield :javascripts %>
<script>
I18n = I18n || {}
I18n.defaultLocale = "<%= I18n.default_locale %>"
I18n.locale = "<%= I18n.locale %>"
</script>
<span data-parsley-namespace='parsley-'></span>
<% if current_role?([:nonprofit_associate, :nonprofit_admin, :super_admin]) && yield(:hide_nav_beacon) != 'true' %>
<%= render 'layouts/nav_beacon' %>
<% end %>