Skip to content

Instantly share code, notes, and snippets.

View clamstew's full-sized avatar
🧘
🎨 🤖 🚀 vibe-coding 24/7. Let's Go!

Clay Stewart clamstew

🧘
🎨 🤖 🚀 vibe-coding 24/7. Let's Go!
View GitHub Profile
@clamstew
clamstew / call_apply_example.html
Created May 30, 2014 16:12
A basic example of call and apply
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Call and Apply</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
@clamstew
clamstew / foreach_call.html
Created May 30, 2014 16:10
Example of using call in a foreach function
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Looking at Call</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
@clamstew
clamstew / constructor_example.html
Created May 27, 2014 16:13
A larger constructor with multiple instances to ponder ...
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Constructor Functions</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
@clamstew
clamstew / closure_and_contructor.html
Created May 27, 2014 16:12
A small maker nap constructor to ponder
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>My Title</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
</head>
<body>
@clamstew
clamstew / modal_example.html
Last active August 29, 2015 14:01
this shows a basic modal window
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>My Title</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<!-- <link rel="stylesheet" href="style.css"> -->
<style type="text/css">
@clamstew
clamstew / rps.rb
Created May 21, 2014 18:21
Show commenting out require relatives and putting in the directory files in a single line
# Create our module. This is so other files can start using it immediately
module RPS
end
# Require all of our project files
# require_relative 'rps/player.rb'
# require_relative 'rps/match.rb'
# require_relative 'rps/round.rb'
<div id="result">result text</div>
(function(){
var resizeText = function() {
var text = $("#result").html();
var length = text.length;
if (length > 30){
$("#result").css("font-size", "0.7em");
}
@clamstew
clamstew / resizer.js
Last active August 29, 2015 14:01
margin top resizer
(function(){
var marginSetter = function () {
var h = ($(window).height()) / .2;
$('#my-element').css("margin-top": h);
};
// to run when the window is resized
$(window).on('resize', function() {
marginSetter();
@clamstew
clamstew / clearfix.html
Created May 7, 2014 21:03
Add a sample page for the clearfix lesson
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Clearfix Example</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type="text/css">
/* code for debugging */
@clamstew
clamstew / shoestring-style-guide.html
Last active August 29, 2015 14:01
style-guide for project shoestring sass
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>Shoestring.css Style Guide</title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="./css/shoestring/0.0.1/shoestring-dev.css">
<style type="text/css">