Skip to content

Instantly share code, notes, and snippets.

View .tmux.conf
# Settin: the prefix from Ctrl-b to Ctrl-a
set -g prefix C-a
# Free the original Ctrl-b prefix keybinding
unbind C-b
# setting the delay between the prefix and command:
set -s escape-time 1
# Set the base index for windows to 1 instead of 0
View workshop-05-solution.js
let max = 100;
let min = 1;
let nGuesses = 0;
let currGuess = 0;
/* getElementById would be fine to use below as well instead of querySelector */
const yesBtn = document.querySelector('#yesBtn');
const noBtn = document.querySelector('#noBtn');
const higherBtn = document.querySelector('#higherBtn');
const lowerBtn = document.querySelector('#lowerBtn');
const startBtn = document.querySelector('#startBtn');
View generate-fix.js
//import inquirer
const inquirer = require('inquirer');
//import jest
const jest = require('jest');
//require Engineer, intern, manager
const Engineer = require('./lib/Engineer.js');
const Intern = require('./lib/Intern.js');
const Manager = require('./lib/Manager.js');
//write to html pageDisplay
const fs = require('fs');
View okta-slo-vue.js
<div id="home">
<div v-if="this.$parent.authenticated">
<button v-on:click="logout()">
kingluddite /
Created Apr 15, 2021
CSS boilerplate - clone into a folder with existing files

Add a CSS boilerplate with useful dev tools quickly

  • If you want to use stylelint, eslint, prettier, css boilerplate to any project and install all of the dependencies with a simple call to a function

How to execute

  • Add this function to your dotfiles
  • After making change to dotfile make sure to source it $ source functions (assuming you have a file named functions holding all of your functions in your dotfiles)
  • Also make sure you are working in a new terminal session when running this function if you make changes or you will not be running the new function)
  • run with $ css-boilerplate
kingluddite / jquery-dynamic.js
Created May 15, 2020
dynamic jquery elements
View jquery-dynamic.js
$(document).ready(function() {
console.log("click code works!");
var root = document.querySelector("#empty-area");
root.innerHTML =
"<button id='name-btn'>Click to see my name</button><div id='name'></div>";
$("#empty-area").on("click", "#name-btn", function() {
$("#name").html("John Jacob Jingleheimer-Schmidt");
View object.js
var characters = [
routeName: "yoda",
name: "Yoda",
role: "Jedi Master",
age: 900,
forcePoints: 2000
routeName: "darthmaul",
View script.js
console.log('i am a coder')
View game.xml
<?xml version="1.0" encoding="UTF-8"?><Deck><Cards CatID="56142" Quantity="1" Sideboard="false" Name="Acid-Spewer Dragon"/><Cards CatID="55983" Quantity="1" Sideboard="false" Name="Belltoll Dragon"/><Cards CatID="18920" Quantity="1" Sideboard="false" Name="Bladewing's Thrall"/><Cards CatID="68337" Quantity="1" Sideboard="false" Name="Bone Dragon"/><Cards CatID="65687" Quantity="1" Sideboard="false" Name="Boneyard Scourge"/><Cards CatID="6845" Quantity="1" Sideboard="false" Name="Catacomb Dragon"/><Cards CatID="20056" Quantity="1" Sideboard="false" Name="Clockwork Dragon"/><Cards CatID="38961" Quantity="1" Sideboard="false" Name="Cloud Dragon"/><Cards CatID="55894" Quantity="1" Sideboard="false" Name="Deathbringer Regent"/><Cards CatID="15279" Quantity="1" Sideboard="false" Name="Draco"/><Cards CatID="56080" Quantity="1" Sideboard="false" Name="Dragonloft Idol"/><Cards CatID="55934" Quantity="1" Sideboard="false" Name="Dragonlord Silumgar"/><Cards CatID="38954" Quantity="1" Sideboard="false" Name="Ebon Dragon"
kingluddite /
Last active Mar 31, 2020
This is what needs to be in a README

Homework assignments must ALL be accompanied with a comprehensive README. The README must contain at minimum a description of what the project is, technologies used, screenshots of essential code, and gif walkthroughs of the application functioning. Homework will be issued an incomplete if submitted with an unsatisfactory README.