Skip to content

Instantly share code, notes, and snippets.

@er1chu
Last active October 31, 2021 06:14
Show Gist options
  • Save er1chu/d27d89e3f9e27a157b69fd716b8b8aba to your computer and use it in GitHub Desktop.
Save er1chu/d27d89e3f9e27a157b69fd716b8b8aba to your computer and use it in GitHub Desktop.
china friendly jquery cdn snippet
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.1.0/jquery.min.js"></script>
<!-- If jQuery object returns an error (e.g. blocked in Google CDN blocked in China) fallback to this CDN -->
<script> window.jQuery || document.write('<script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"><\/script>');</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment