Leonard Weise

leowe

Home

My Stack

Here's where I'm currently most productive:

A desk with a large monitor, a laptop, a keyboard, headphones and a coffee cup.

1. DB

I've found serverless Postgres for general and Mysql for heavy duty lifting, and libsql for near-edge hosting, to be incredibly powerful.

  • Mysql for performance
  • Libsql for low-latency
  • Postgres for everything else

2. ORM

For TypeScript, I've found Drizzle ORM the best to work with in fast iteration cycles

import { numeric, pgTable, serial, timestamp } from "drizzle-orm/pg-core";

export const metrics = pgTable("metrics", {
  id: serial("id").primaryKey(),
  timestamp: timestamp("timestamp").notNull(),
  value: numeric("value", { precision: 18, scale: 8 }).notNull(),
  volatility: numeric("volatility", { precision: 10, scale: 4 }),
  volume: numeric("volume", { precision: 16, scale: 2 }),
});

3. Rendering

I use React Server Components extensively, enhanced with tRPC for end-to-end type safety:

// Financial data fetching with tRPC
export default async function Dashboard() {
  const data = await api.metrics.getDaily.query({
    metrics: ['volatility', 'volume'],
    timeframe: '24h'
  });

  return (
    <DataGrid
      metrics={data}
      components={{
        VolumeChart: () => <VolumeAnalysis data={data.volume} />,
        VolatilitySeries: () => <VolatilityIndicator data={data.volatility} />
      }}
    />
  )
}

4. Dev Tools

  • Bun for the fastest build times and smallest bundle sizes
  • Typebox for runtime type validation
  • Redis for high-performance caching
  • Python + NumPy for complex financial computations

5. Style

  • Performance-first mindset, especially for financial data processing
  • Strong type safety throughout the stack
  • Careful attention to numerical precision in financial calculations
  • Real-time capabilities through WebSocket integrations
  • Comprehensive testing for calculation accuracy