Skip to content

Instantly share code, notes, and snippets.

View CodeOfficer's full-sized avatar

Russell Jones CodeOfficer

View GitHub Profile
// A fix for the ember chrome extension so that we can peek into the data store
// see https://github.com/stefanpenner/ember-app-kit/issues/263#issuecomment-28482992
/* global require */
export default DS.DebugAdapter.reopen({
getModelTypes: function() {
var self = this;
return Ember.keys(requirejs._eak_seen).filter(function(key) {
return !!key.match(/^appkit\/models\//) && self.detect(require(key)['default']);
{
"color_scheme": "Packages/Color Scheme - Default/Monokai.tmTheme",
"draw_minimap_border": true,
"draw_white_space": "all",
"ensure_newline_at_eof_on_save": true,
"highlight_line": true,
"ignored_packages":
[
"Vintage"
],

Keybase proof

I hereby claim:

  • I am codeofficer on github.
  • I am codeofficer (https://keybase.io/codeofficer) on keybase.
  • I have a public key whose fingerprint is E210 A1C5 3588 530F 8660 B063 F260 F399 D9C9 3D38

To claim this, I am signing this object:

@CodeOfficer
CodeOfficer / dad-jokes.js
Last active August 12, 2018 18:19
Dad Jokes
const dadJokes = {
random() {
return this.jokes[Math.floor(Math.random() * this.jokes.length)];
},
jokes: [
"Did you hear about the restaurant on the moon? Great food, no atmosphere.",
"What do you call a fake noodle? An impasta.",
"How many apples grow on a tree? All of them.",
"Want to hear a joke about paper? Nevermind, it's tearable.",
"I just watched a documentary about beavers. It was the best dam show I've ever seen.",
@CodeOfficer
CodeOfficer / Game-parse.js
Last active March 6, 2020 17:39
Parse PS4 game data
// vist https://store.playstation.com/en-us/home/games
// look at localstorage
// copy your entitlements data and substitue for GAME_DATA below
const games = GAME_DATA;
const sortedGames = games.sort(function(a, b) {
var textA = a.game_meta.name.toUpperCase();
var textB = b.game_meta.name.toUpperCase();
return (textA < textB) ? -1 : (textA > textB) ? 1 : 0;
{"lastUpload":"2020-08-13T16:51:00.817Z","extensionVersion":"v3.4.3"}
echo code --install-extension
code --install-extension aaron-bond.better-comments
code --install-extension alefragnani.project-manager
code --install-extension ardenivanov.svelte-intellisense
code --install-extension cbuelter.vscode-toggle-max-editor
code --install-extension christian-kohler.path-intellisense
code --install-extension DavidAnson.vscode-markdownlint
code --install-extension dbaeumer.vscode-eslint
code --install-extension donjayamanne.githistory
code --install-extension dracula-theme.theme-dracula
// eslint-disable-next-line no-unused-vars
import { timestamp, files, shell, routes } from '@sapper/service-worker';
const ASSETS = `cache${timestamp}`;
// `shell` is an array of all the files generated by the bundler,
// `files` is an array of everything in the `static` directory
const to_cache = shell.concat(files);
const cached = new Set(to_cache);
import Controller from '@ember/controller';
import { computed, set } from '@ember/object';
import { later } from '@ember/runloop';
import { tracked } from '@glimmer/tracking';
export default class ApplicationController extends Controller {
@tracked _cart = null;
@computed('cart')
get outputDude() {