Skip to content

Instantly share code, notes, and snippets.

View CWSpear's full-sized avatar

Cameron Spear CWSpear

View GitHub Profile
@CWSpear
CWSpear / crash-1.md
Last active April 18, 2021 08:25
Crash Reviews
View crash-1.md

Crash Bandicoot

(Note: I played this as part of the Crash Bandicoot N. Sane Trilogy.)

Date of Review: 17 Apr 2021

Status: Lucky to have gotten to credits.

tl;dr: Crash 1 sucked, but each numbered Crash gets a lot better.

@CWSpear
CWSpear / keybase.md
Last active September 12, 2019 07:14
View keybase.md

Keybase proof

I hereby claim:

  • I am cwspear on github.
  • I am cwspear (https://keybase.io/cwspear) on keybase.
  • I have a public key ASAwLIiSBAGa4R9WD7NthgxpTker-RrK96NKcFaQURNMUgo

To claim this, I am signing this object:

@CWSpear
CWSpear / awesome-layout.html
Last active August 29, 2015 14:17
Handling filtering, sorting and pagination without any controller logic
View awesome-layout.html
<!-- "items" is the items in the full list, "displayed" is the items it'll show after filtering, sorting and paging -->
<awesome-list items="users" displayed="displayedUsers">
<div class="pre-table-header">
<!-- input for search placed here -->
<awesome-search></awesome-search>
<button class="btn btn-primary" ui-sref=".user({ id: 'new' })">Add User</button>
</div>
<table class="table">
@CWSpear
CWSpear / index.html
Created October 22, 2012 05:53
A CodePen by douglasdeodato. Single Element Pure CSS MacBook Pro - This is just an experiment! There are certainly better ways to show an image of a MacBook, but none as fun as this :)
View index.html
<i class="macbook"></i>
@CWSpear
CWSpear / jshint.json
Created October 11, 2012 18:17
My JSHint Settings (used in CodeKit and Sublime Text 2 via SublimeLinter)
View jshint.json
{
"bitwise": true,
"eqeqeq": true,
"latedef": true,
"newcap": true,
"noarg": true,
"nonew": true,
"regexp": true,
"trailing": true,
@CWSpear
CWSpear / config.rb
Created October 10, 2012 00:52
concrete5: Compass + Sass: handle typography.css (moves typography.css up one directory when you compile stylesheets)
View config.rb
# after your other config stuff add:
require 'fileutils'
on_stylesheet_saved do |file|
if File.exists?(file) && File.basename(file) == "typography.css"
puts "Moving: #{file}" # optional line, just letting you know what's going
FileUtils.mv(file, File.dirname(file) + "/../" + File.basename(file))
end
end
@CWSpear
CWSpear / object_merge.php
Created September 18, 2012 19:11
object_merge for php
View object_merge.php
<?php
$one->one = 1;
$two->two->one = 21;
$two->two->two = 22;
$three->two->one = 31;
$return_obj = object_merge($one, $two, $three);
// returns:
// Array
@CWSpear
CWSpear / current-page-link-highlighter.js
Created August 22, 2012 20:43
Highlight all links pointing to the current page. This works a bit more effectively because it uses .prop() as opposed to .attr(), but requires jQuery 1.6 or greater.
View current-page-link-highlighter.js
@CWSpear
CWSpear / index.html
Created July 11, 2012 03:16
A web page created at CodePen.io
View index.html
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Blob &middot; CodePen</title>
<!--
Copyright (c) 2012 Hakim El Hattab, http://codepen.io/hakimel
Permission is hereby granted, free of charge, to any person obtaining
@CWSpear
CWSpear / index.html
Created July 11, 2012 03:16
A web page created at CodePen.io
View index.html
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>Blob &middot; CodePen</title>
<!--
Copyright (c) 2012 Hakim El Hattab, http://codepen.io/hakimel
Permission is hereby granted, free of charge, to any person obtaining