Skip to content

Instantly share code, notes, and snippets.

View jgierer12's full-sized avatar

Jonas Gierer jgierer12

View GitHub Profile

[This portion of call begins at 25:47]

Me: I could make it really easy on you, if you think Apollo is costing you $20 million per year, cut me a check for $10 million and we can both skip off into the sunset. Six months of use. We're good. That's mostly a joke.

Reddit: Six months of use? What do you mean? I know you said that was mostly a joke, but I want to take everything you're saying seriously just to make sure I'm not - what are you referring to?

Me: Okay, if Apollo's opportunity cost currently is $20 million dollars. At the 7 billion requests and API volume. If that's your yearly opportunity cost for Apollo, cut that in half, say for 6 months. Bob's your uncle.

Reddit: You cut out right at the end. I'm not asking you to repeat yourself for a third time, but you legit cut out right at the end. "If your opportunity cost is $10 million" and then I lost you.

@qguv
qguv / vscode-wayland.md
Last active April 3, 2024 06:40
Visual Studio Code: Enable native Wayland support

Native wayland support is now working consistently for me in VSCode, giving much better text rendering. Unfortunately, it's still hidden behind some command-line flags.

By adding some files to /usr/local/*, you can ensure that VSCode always launches with these flags.

Adding launch flags to VSCode

Assuming that the VSCode launcher is /usr/bin/code-oss (as is the case in Arch):

  1. Create /usr/local/bin/code-oss with the following content:
export const h=(t,p,...c)=>({t,p,c,k:p&&p.key})
export const render=(e,d,t=d.t||(d.t={}),p,r,c,m,y)=>
// arrays
e.map?e.map((e,p)=>render(e,d,t.o&&t.o[p])):
// components
e.t.call?(e.i=render((render.c=e).t(Object.assign({children:e.c},e.p),e.s=t.s||{},t=>
render(Object.assign(e.s,t)&&e,d,e)),t.i||d,t&&t.i||{}),d.t=t=e):(
// create notes
m=t.d||(e.t?document.createElement(e.t):new Text(e.p)),
// diff props
@dominictarr
dominictarr / readme.md
Created November 26, 2018 22:39
statement on event-stream compromise

Hey everyone - this is not just a one off thing, there are likely to be many other modules in your dependency trees that are now a burden to their authors. I didn't create this code for altruistic motivations, I created it for fun. I was learning, and learning is fun. I gave it away because it was easy to do so, and because sharing helps learning too. I think most of the small modules on npm were created for reasons like this. However, that was a long time ago. I've since moved on from this module and moved on from that thing too and in the process of moving on from that as well. I've written way better modules than this, the internet just hasn't fully caught up.

@broros

otherwise why would he hand over a popular package to a stranger?

If it's not fun anymore, you get literally nothing from maintaining a popular package.

One time, I was working as a dishwasher in a restu

Preact for Angular 1 Users

Here's my quick attempt to build a tiny preact app using terminology from Angular 1.

Installation

# get it
git clone https://gist.github.com/e5de4c33c1a8d8fd172905010d3ff75c.git preact-for-angular1-users
cd preact-for-angular1-users
@jlong
jlong / micro-reset.scss
Created May 17, 2017 16:14
Micro CSS reset
// micro-reset.scss
//
// Based on the Meyer reset
// Universal selector works great!
// See: http://blogs.telerik.com/kendoui/posts/12-09-28/css_tip_star_selector_not_that_bad
*, *::before, *::after {
margin: 0;
padding: 0;
border: 0;
@malarkey
malarkey / Contract Killer 3.md
Last active April 16, 2024 21:44
The latest version of my ‘killer contract’ for web designers and developers

When times get tough and people get nasty, you’ll need more than a killer smile. You’ll need a killer contract.

Used by 1000s of designers and developers Clarify what’s expected on both sides Helps build great relationships between you and your clients Plain and simple, no legal jargon Customisable to suit your business Used on countless web projects since 2008

…………………………

@Dinnerbone
Dinnerbone / gist:3736487
Created September 17, 2012 09:49
New Minecraft target selector syntax!

Syntax

All target selectors start with @. The following character is the selector type. For example, @p means 'closest player'.

Target selectors may have additional, optional arguments. You can specify these in [ ], using the syntax a=0. For example, @p[a=0,b=5,c=-500].

There is a special short syntax for just specifying x, y, z and r arguments; simply list their values separated by a comma, without x=. For example: @p[100,64,-100,5] for 5 range, x=100, y=64 and z=-100. Each of these are optional and skippable by leaving them empty. For example, to just specify y coordinate: @p[,64].

Global Arguments:

  • x - X coordinate for search center. Default is senders coordinate, or 0.
  • y - Y coordinate for search center. Default is senders coordinate, or 0.
@piscisaureus
piscisaureus / pr.md
Created August 13, 2012 16:12
Checkout github pull requests locally

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url = git@github.com:joyent/node.git

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this: