Skip to content

Instantly share code, notes, and snippets.

View heiso's full-sized avatar

Alexandre Moatty heiso

View GitHub Profile
@heiso
heiso / generate-remix-routes.ts
Last active December 3, 2024 21:38
Generate remix routes
import { readConfig } from '@remix-run/dev/dist/config.js'
import type { ConfigRoute, RouteManifest } from '@remix-run/dev/dist/config/routes.js'
import { writeFileSync } from 'fs'
import { format, resolveConfig } from 'prettier'
const outputPath = `routes.ts`
function buildPath(routes: RouteManifest, route: ConfigRoute): string {
const result = []
if (route.parentId) {
@ruizb
ruizb / README.md
Last active January 17, 2025 13:06
A glossary of TypeScript.

A glossary of TypeScript

Motivation

Once upon a time, there was a developer that had an issue using the TypeScript language. He wanted to share his issue with the community to get help, but he didn't know how to properly write the title that would best describe his problem. He struggled to find the appropriate words as he didn't know how to name "this behavior" or "that kind of type mechanism".

This story encouraged me to start writing a glossary of TypeScript. Hopefully it will help you if you have to look for an issue, write an issue, or communicate with other TypeScript developers.

Disclaimer: it was me, I was the developer that struggled. I still struggle though, but this means I still have things to learn, which is great!