Skip to content

Instantly share code, notes, and snippets.

View bingomanatee's full-sized avatar

Dave Edelhart bingomanatee

View GitHub Profile
@bingomanatee
bingomanatee / CaseRow.js
Created January 10, 2022 19:51
CaseRow.js
import DateRep from "./DateRep";
import { Prisma } from '@prisma/client'
function asInt(value) {
const i = parseInt(value);
if (isNaN(i)) {
return 0;
} else {
return i;
}
  1. Action Names:

these are constants (usu. strings) that are the names that identify what you are doing. Think of it like the names of functions. An action is a name-payload pair that moves through the Redux/Saga state system. This is a formalization of a function call

  1. Action Functions:

These take in arguments and return an object in the form

{ action: <>

1. Action Names:
these are constants (usu. strings) that are the names that identify what you are doing. Think of it like the names of functions. An action is a name-payload pair that moves through the Redux/Saga state system. This is a formalization of a function call
2. Action Functions:
These take in arguments and return an object in the form
{
action: <<string>>
@bingomanatee
bingomanatee / create-article-table.js
Created August 26, 2018 20:31
Article Migration
'use strict';
module.exports = {
async up(queryInterface, Sequelize) {
const { sequelize } = queryInterface;
await sequelize.query('CREATE EXTENSION IF NOT EXISTS "uuid-ossp";');
return sequelize.transaction(async (transaction) => {
await queryInterface.createTable('articles', {
id: {
@bingomanatee
bingomanatee / .neutrinorc.js
Created May 13, 2018 00:23
a react neutrino-rc seed file with a few useful add-ins
module.exports = {
use: [
['@neutrinojs/react',
{
host: 'edelbucks.biz',
html: {
baseHref: '/',
headHtmlSnippet: `<style type="text/css">body, html {margin: 0; padding: 0; height: 100%; overflow-x: hidden; overflow-y: auto;}</style>`,
title: 'EdelBucks',
links: [
@bingomanatee
bingomanatee / jasmine_helper.rb
Created September 9, 2016 19:00
helper patch
#Use this file to set/override Jasmine configuration options
#You can remove it if you don't need it.
#This file is loaded *after* jasmine.yml is interpreted.
#
#Example: using a different boot file.
#Jasmine.configure do |config|
# config.boot_dir = '/absolute/path/to/boot_dir'
# config.boot_files = lambda { ['/absolute/path/to/boot_dir/file.js'] }
#end
#
<!DOCTYPE html>
<html>
<head>
<script data-require="[email protected]" data-semver="1.4.8" src="https://code.angularjs.org/1.4.8/angular.js"></script>
<link rel="stylesheet" href="style.css" />
<script src="papa-csv.js"></script>
<script src="data.js"></script>
<script src="script.js"></script>
</head>
define(['angular', 'javascript-state-machine'], function (angular, StateMachine) {
angular.module('AwaitingActivationCtrl', [])
.controller('AwaitingActivationCtrl', ['$scope', '$timeout', function ($scope, $timeout) {
var results = ['parking', 'validating', 'activating', 'finished', 'finished']
var rIndex = 0;
$scope.delay = 1500;
$scope.stateMessage = '~#0';
$scope.calls = 0;
@bingomanatee
bingomanatee / gist:a2c313e73f16631e7b6c
Created April 3, 2015 20:40
Conversation with Capital One
4/2/2015 Capital One Chat
Welcome to our Capital One secure chat service! This chat will be monitored and recorded.
You 01:39 PM
You guys keep calling me to call you back. I'm paid up ­­ please stop calling me.
You 01:39 PM
David Edelhart
Sean 01:40 PM
Hello David.
Sean 01:40 PM
I apologize for any inconvenience happened.
using UnityEngine;
using System.Collections;
using System.Collections.Generic;
using System.IO;
using SimpleJSON;
namespace P1
{
public class Utils
{