2
0
mirror of https://github.com/tenrok/bootstrap.git synced 2026-05-15 11:59:39 +03:00

Use the SRI hashes for the live site's assets. (#25282)

This commit is contained in:
XhmikosR
2018-01-16 00:56:30 +02:00
committed by GitHub
parent 1f490ec165
commit e6d9316ba0
2 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -14,7 +14,7 @@
<!-- Bootstrap core CSS -->
{% if site.github %}
<link href="{{ site.baseurl }}/dist/css/bootstrap.min.css" rel="stylesheet">
<link href="{{ site.baseurl }}/dist/css/bootstrap.min.css" rel="stylesheet" integrity="{{ site.cdn.css_hash }}" crossorigin="anonymous">
{% else %}
<link href="{{ site.baseurl }}/dist/css/bootstrap.css" rel="stylesheet">
{% endif %}
+2 -2
View File
@@ -1,10 +1,10 @@
<script src="{{ site.cdn.jquery }}" integrity="{{ site.cdn.jquery_hash }}" crossorigin="anonymous"></script>
<script>window.jQuery || document.write('<script src="{{ site.baseurl }}/assets/js/vendor/jquery-slim.min.js"><\/script>')</script>
<script src="{{ site.baseurl }}/assets/js/vendor/popper.min.js"></script>
<script src="{{ site.baseurl }}/assets/js/vendor/popper.min.js"{% if site.github %} integrity="{{ site.cdn.popper_hash }}" crossorigin="anonymous"{% endif %}></script>
{%- if site.github -%}
<script src="{{ site.baseurl }}/dist/js/bootstrap.min.js"></script>
<script src="{{ site.baseurl }}/dist/js/bootstrap.min.js" integrity="{{ site.cdn.js_hash }}" crossorigin="anonymous"></script>
{%- else -%}
<script src="{{ site.baseurl }}/dist/js/bootstrap.js"></script>
{%- endif -%}