You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

18 lines
439 B

  1. $(function() {
  2. $(".json-response").each(function(idx, el) {
  3. $.getJSON(el.dataset.url, function(data) {
  4. el.innerHTML = "<code>" + JSON.stringify(data) + "</code>";
  5. });
  6. });
  7. $("#show-svg").click(function() {
  8. $("#badges-json").hide();
  9. $("#badges-svg").show();
  10. })
  11. $("#show-json").click(function() {
  12. $("#badges-svg").hide();
  13. $("#badges-json").show();
  14. })
  15. });