Skip to content

Instantly share code, notes, and snippets.

// https://stackoverflow.com/questions/7341865/checking-if-jquery-is-loaded-using-javascript
$(document).ready(function(){
if (jQuery) {
// jQuery is loaded
alert("Yeah!");
} else {
// jQuery is not loaded
alert("Doesn't Work");
}
<html>
<head>
<?php
function social_card($og_obj) {
/*
$og_obj = array(
"tw_username" => "vassar",
"preview_image" => "https://www.vassar.edu/assets/images/home-slideshow-sustainability-standard.jpg",
.full-bleed {
width: 100vw;
margin-left: 50%;
transform: translateX(-50%);
}
/* https://andy-bell.design/wrote/creating-a-full-bleed-css-utility/ */
$( document ).ready(function() {
var discreteElements = document.getElementsByClassName('animate-this')
for (var i = 0; i < discreteElements.length; i++) {
new Waypoint({
element: discreteElements[i],
handler: function() {
this.element.classList.add("animation");
},
offset: '50%'
});
scss/.sass-cache
scss/.sass-cache/*
scss/*/.sass-cache
scss/*/*/.sass-cache
@csilverman
csilverman / markupifier.php
Created March 15, 2018 22:31
Script to take line-delimited content and merge it with a template.
<?php
/* Item formatter
==============
This script takes data in a set of line-delimited items, as follows:
Arthur Arthurson
From: Phoenix, AZ
Major: Political Science