Skip to content

Instantly share code, notes, and snippets.

View mrpotatoes's full-sized avatar

Andric LibreSinn mrpotatoes

View GitHub Profile
@ozh
ozh / markdown_image_border.md
Created May 14, 2020 16:30
Image border in markdown

Image in markdown: no style possible

![alt-text](https://raw.githubusercontent.com/YOURLS/YOURLS/1.7.9/images/yourls-logo.png)

alt-text

IMG tag accepts no style

<img src="https://raw.githubusercontent.com/YOURLS/YOURLS/1.7.9/images/yourls-logo.png" border="1px solid red"/>

So here's the deal. I hyper recommend all-clad but it's expensive and can be a pain in the ass to deal with esp if you're new to cooking. I can help with that. We can do a zoom meeting to do some cooking practice.

Anyhow, you're going to want some cheap pieces that you care less about or are easier to work with.

Almost everything I'm going to


https://tinyurl.com/urow74q

A cast iron skillet is going to be one of your most used items in the kitchen. Cleaning couldn't be easier. Hit it with hot water and you're done. If you gotta do more then you can use

@waynevanson
waynevanson / match-ts.ts
Created April 12, 2020 10:29
A port of switch-case statements for fp-ts.
/**
* A port of switch-case statements for fp-ts.
*
* This could be broken down further and perhaps extended into a new type-class.
* It does the specific job I needed it to.
*
* If you have an abstraction that might help, i'd love to hear about it!
*/
import { array, either, option } from "fp-ts";
@ruizb
ruizb / advanced-example.md
Last active September 26, 2023 20:21
Reader monad example using fp-ts

The following section is not part of monet.js documentation, but I think it's worth showing how we can compose readers using fp-ts.

Reader composition

Let's say we have the following piece of code:

interface Dependencies {
  logger: { log: (message: string) => void }
 env: 'development' | 'production'
@panoply
panoply / equal-width.md
Last active November 10, 2024 01:17
2 column full width table for github markdown

Equal widths

Github markdown full-width 2 column table.

@Gustavo-Kuze
Gustavo-Kuze / force-ctrl-c-v.md
Last active November 16, 2024 16:01
Enable copy and paste in a webpage from the browser console
javascript:(function(){
  allowCopyAndPaste = function(e){
  e.stopImmediatePropagation();
  return true;
  };
  document.addEventListener('copy', allowCopyAndPaste, true);
  document.addEventListener('paste', allowCopyAndPaste, true);
  document.addEventListener('onpaste', allowCopyAndPaste, true);
})(); 
@gvolpe
gvolpe / di-in-fp.md
Last active September 16, 2024 07:18
Dependency Injection in Functional Programming

Dependency Injection in Functional Programming

There exist several DI frameworks / libraries in the Scala ecosystem. But the more functional code you write the more you'll realize there's no need to use any of them.

A few of the most claimed benefits are the following:

  • Dependency Injection.
  • Life cycle management.
  • Dependency graph rewriting.
@chrislaughlin
chrislaughlin / travis.md
Created March 31, 2018 16:20
Using Travis CI with Gatsby

First set out your build scripts In your package.json scripts and install the gh-pages npm module

"build": "gatsby build",
"test": "echo \"no test specified\" && exit 0",
"preDeploy": "gatsby build --prefix-paths",
"deploy": "npm run preDeploy && gh-pages -d public"

Connect Travis CI to your repo and in the repo settings add an enviroment var call GITHUB_TOKEN with the value of your github token from:

@ksmithut
ksmithut / .dockerignore
Last active September 26, 2024 04:42
Node Docker Compose nodemon
node_modules
@richard512
richard512 / reenable-right-click.js
Created July 7, 2017 01:55
re-enable right click (bookmarklet)
javascript:(function(w){
var arr = ['contextmenu','copy','cut','paste','mousedown','mouseup','beforeunload','beforeprint'];
for(var i = 0, x; x = arr[i]; i++){
if(w['on' + x])w['on' + x] = null;
w.addEventListener(x, function(e){e.stopPropagation()}, true);
};
for(var j = 0, f; f = w.frames[j]; j++){try{arguments.callee(f)}catch(e){}}})(window);