Skip to content

Instantly share code, notes, and snippets.

@kirkouimet
kirkouimet / 779244.html
Last active October 30, 2017 16:11
We need a way to wrap console.log and preserve the file and line number
<html>
<head>
<title>We need a way to wrap console.log and preserve the file and line number</title>
<script>
function customLog() {
var processedArguments = arguments;
// Do something with the arguments besides logging them, maybe format them or store them
// ...
// Send the output to Developer Tools
Verifying my Blockstack ID is secured with the address 1KfdWMJuVKdLB2eCLXNxnkmU1TmdzC9rfM https://explorer.blockstack.org/address/1KfdWMJuVKdLB2eCLXNxnkmU1TmdzC9rfM
var view = new View();
view.width = 1024;
view.height = 768;
view.render();
@kirkouimet
kirkouimet / OrderIdentifierGenerator.js
Last active May 5, 2023 16:30
Generate an easy to communicate order identifier with a check digit with a keyspace in the trillions
class OrderIdentifierGenerator {
static characters = '234567CDFGHJKLMNPQRTVWXYZ';
// Generate a new identifier
static generate() {
const partialIdentifier = OrderIdentifierGenerator.generatePartialIdentifier();
let identifier = (
partialIdentifier.slice(0, 3) +