Skip to content

Instantly share code, notes, and snippets.

View nickytonline's full-sized avatar
🚀

Nick Taylor nickytonline

🚀
View GitHub Profile
import "https://deno.land/x/dotenv/load.ts";
const response = await fetch("https://www.getrevue.co/api/v2/issues", {
headers: {
Authorization: `Token ${Deno.env.get("REVUE_API_KEY")}`,
},
});
const issues = await response.json();
@threepointone
threepointone / feature-flags-client-implementation.md
Last active June 1, 2023 18:35
Implementing a client for feature flags

On implementing a client for feature flags in your UI codebase

This document isn't an explainer on Feature Flags, you can find that with my amateur writeup, or literally hundreds of better writeups out there.

This document is also agnostic to the choice of service you'd use: LaunchDarkly or split.io or optimizely or whatever; that's orthogonal to this conversation.

Instead, this document is a list of considerations for implementing a client for using Feature Flags for User Interface development. Service providers usually give a simple fetch and use client and that's it; I contend that there's a lot more to care about. Let's dive in.

To encourage usage, we'd like for the developer experience to be as brutally simple as possible. So, this should be valid usage:

@nickcernis
nickcernis / docker-cleanup.md
Last active May 31, 2024 08:28
Docker commands to remove all containers and images

docker kill $(docker ps -q) to kill all running containers
docker rm $(docker ps -a -q) to delete all stopped containers.
docker volume rm $(docker volume ls -q) to delete all volumes.
docker rmi $(docker images -q) to delete all images.

Run all commands:

docker kill $(docker ps -q) && docker rm $(docker ps -a -q) && docker volume rm $(docker volume ls -q) && docker rmi $(docker images -q)

For fish shell, remove the $:

@CodeMouse92
CodeMouse92 / beginners-tag.md
Last active March 6, 2024 06:03
DEV.to Moderation Comments and Messages

MOVED TO https://github.com/CodeMouse92/DEVModInACan

#BEGINNERS TAG REMOVALS

Non-Beginner Article

All articles on #beginners should be written for those new to programming, development, networking, or to a particular language. These posts should also require little to no prerequisite knowledge. If you wish, you may rewrite your post to meet these requirements, at which point you may request that the tag be added back. Otherwise, just use the appropriate technology tags. (Read more about the tag rules here.)

Non-Beginner Question

@swalkinshaw
swalkinshaw / tutorial.md
Last active November 13, 2023 08:40
Designing a GraphQL API
@mrmartineau
mrmartineau / stimulus.md
Last active May 12, 2024 04:35
Stimulus cheatsheet
@timvisee
timvisee / falsehoods-programming-time-list.md
Last active May 31, 2024 20:26
Falsehoods programmers believe about time, in a single list

Falsehoods programmers believe about time

This is a compiled list of falsehoods programmers tend to believe about working with time.

Don't re-invent a date time library yourself. If you think you understand everything about time, you're probably doing it wrong.

Falsehoods

  • There are always 24 hours in a day.
  • February is always 28 days long.
  • Any 24-hour period will always begin and end in the same day (or week, or month).
@fokusferit
fokusferit / enzyme_render_diffs.md
Last active April 15, 2024 09:41
Difference between Shallow, Mount and render of Enzyme

Shallow

Real unit test (isolation, no children render)

Simple shallow

Calls:

  • constructor
  • render
@joepie91
joepie91 / promises-faq.md
Last active June 25, 2023 09:02
The Promises FAQ - addressing the most common questions and misconceptions about Promises.
@piotrwitek
piotrwitek / tslint.json
Last active April 20, 2019 01:18
TSLint rules with ESLint/React extension based on airbnb style guide
{
"rules": {
"align": [
true,
"parameters",
"arguments",
"statements"
],
"ban": false,
"class-name": true,