Giter Club home page Giter Club logo

til's Introduction

TIL

Today I Learned

A collection of concise write-ups on small things I learn day to day across a variety of languages and technologies. These are things that don't really warrant a full blog post. These are things I've picked up by Learning In Public™ and pairing with smart people at Hashrocket.

For a steady stream of TILs, sign up for my newsletter.

1408 TILs and counting...


Categories


Ack

Amplify

Ansible

Brew

Chrome

Clojure

CSS

Deno

Devops

Docker

Elixir

Gatsby

Git

GitHub Actions

Go

GROQ

Heroku

HTML

HTTP

Inngest

Internet

JavaScript

jq

Kitty

Linux

Mac

MongoDB

MySQL

Neovim

Netlify

NextAuth.js

Next.js

Phoenix

Planetscale

pnpm

PostgreSQL

Prisma

Python

Rails

React

React Native

React Testing Library

ReasonML

Remix

RSpec

Ruby

sed

Shell

SQLite

Streaming

Tailwind CSS

tmux

TypeScript

Unix

Vercel

Vim

VSCode

Webpack

Workflow

XState

YAML

Zod

Usage

The .vimrc file for this project contains a function CountTILs that can be invoked with <leader>c. This will do a substitution count of the current number of TILs and display the result in the command tray.

About

I shamelessly stole this idea from thoughtbot/til.

Other TIL Collections

License

© 2015-2022 Josh Branchaud

This repository is licensed under the MIT license. See LICENSE for details.

til's People

Contributors

bengadbois avatar bhargavrpatel avatar bmaca avatar bortevik avatar dcki avatar jakeonrails avatar jbranchaud avatar mcrapet avatar oxicode avatar patrickdavey avatar prankymat avatar samirboulil avatar sdegutis avatar tumdum avatar verfehlix avatar xyproto avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

til's Issues

go/sleep-for-a-duration.md

It's not correct to say that time.Sleep takes Nanoseconds. It takes a time.Duration as you can see from the signature. Go is strongly typed, so you can't pass an int in there at all.

The confusion is created by the way go handles untyped constants like integer-literals: They don't have a type and arbitrary precision and they get a type inferred at the place they are used. If you use it as an integer-type, like int, uint32, rune… or time.Duration, then that's the inferred type. That's how time.Sleep(42) can work - 42 is then inferred to be a time.Duration. However, that's more an unlucky consequence of the design, than intention. If no type can be inferred - for example when assigning it to a new variable, like x := 42 - a default type (int for integer literals) is used, which is why above link creates a compiler-error.

I acknowledge that the exact details are hard to get right for "outsiders" not familiar with the language, but I just thought I should report that that statement isn't correct, technically :) It's not that time.Sleep takes nanoseconds, it just that a time.Duration is stored as an integer type with nanosecond granularity, so that's how an integer literal in place of a Duration is interpreted.

css: typo

In css/dry-up-scss-with-mixins.md misspelled "navgation"...

Compile md files together in one file for easy reading of TILS of each topic

I tried compiling all markdown files of every category in one file in every directory(category) locally with pandocs
I tried this in powershell

 foreach ($d in $dir){
$folderName = $d.Name;
   pandoc (get-item D:/til/til/$folderName/*.md) -o D:/til/til/$folderName/$folderName-compilation.md
}

this created a compilation file like ack-compilation.md in ack folder containing combined markdown file content,
Maybe someone can automate the process for this github repo as reading TILS together for any particular category is much better than clicking links for every TIL.
This is the result
result

vim/scrolling-relative-to-the-window.md

The above is listed in the README.md, but the actual file is at vim/scrolling-relative-to-the-cursor.md.

Excellent tip by the way, I'll be using this all the time.

vim-til: file name typo

@jbranchaud The line below is referencing vim/turning-off-search-highlighting.md

til/README.md

Line 1342 in 711310b

- [Turning Off Search Highlighting](vim/turning-off-search-highlighting.md)

but the file in that folder is missing an f and is called vim/turning-of-search-highlighting.md

Suggested fix is to rename vim/turning-of-search-highlighting.md -> vim/turning-off-search-highlighting.md

This is an creative idea

I appreciate your guidance on integrating the wisdom

Small changes make great things

into my life

JS: Truthiness of Integer Arrays

Hey! The issue you are seeing there with [0] is not an issue at all. The behaviour is completley normal if you embrace JS coercion (implicit casting) in == operator.

the issue is that in the expression [0] == false, false is actually coerced to a Number by the built-in object Number, and of course: Number(false) is 0!
Then, [0] is first coerced to the String "0" and finally coerced to the Number 0.
So, the last comparision is actually 0 === 0. Which is obviously true.

Hope the explanation shed some light on the subject!

go/not-so-random.md

For security reasons you probably shouldn't have a boilerplate to seed a random number generator with predictable/structured input like the current time (which can be guessed by an attacker). Use crypto/rand to seed your RNG.

It's also possible to recover the state of most PRNGs using the output, so you should usually just use crypto/rand directly for your random data until the RNG becomes your program's bottleneck.

Your newsletters go to spam

Hey there,

Straight from signing up, one will have to look in the trash for the confirmation email. I'm guessing your newsletter will wind up there as well.

I don't think ConverKit is doing anything wrong...they're just sending a message from your email from some wonky-random-generated webpage.

I'm sure if you set these settings up the problem would go away (or not, because it's still gmail!).

This is how ProtonMail shows it, and the sneaker tracker.
image
Believe it or not, this is better than Microsoft 365 in Office, which just auto-trashes it.

The newsletter on your website from tinyletter works just fine :)

Maybe you're not even using the one in the README.md and problem solved with a small edit

"List All The Say Voices" missorted

The guide "List All The Say Voices" is filed under Unix; however, say is an OS X-only command, so it should probably be moved to the Mac folder.

Automate creation of README.md

Hi!
I love the idea and am adopting it myself. I've created a script which will auto-generate the README.md file using the information already in the directory structure and the titles of each of the TIL markdown files. I've got it working and producing output that is close: the diffs are:

  • alphabetization is different when python does it than some of your choices
  • you missed a # in front of Webpack
  • Someplaces you have custom capitalization (CSS instead of Css)
  • You also missed this line:

As I said, I've got the generation script, but I'm still thinking about how to get it into the work-flow. The options I can think of tonight are:

  1. a git hook which runs on pre-commit which modifies the README.md
  2. just have it as a command in the project that can be run manually

Neither of these are making me happy this evening, so I'm asking you if you have any ideas, that is, if you're interested at all.

Either way, Thanks for the great idea! I really like what you did. I'll admit I created my own before I saw your instructions (or thought about) forking your starter repo.

Thanks again!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.