Skip to content

expectfun/defi-visualized

Repository files navigation

defi-visualized

Version 0.1 — AI Coding Alert: This repository was built with AI assistance and is subject to change. While the results have been manually reviewed, there are no guarantees of correctness. Use these visualizations for educational purposes only — do not make financial decisions based on them.

Interactive visualizations that explain DeFi concepts. Each example is a single HTML file with no dependencies — just open in a browser and explore.

Examples

Bonding Curve

Explore how token price changes based on supply. Multiple curve types (linear, quadratic, cubic), buy/sell simulation, and reserve visualization.

AMM Price Impact

Visualize the constant product formula (x × y = k). See how trade size affects slippage and the difference between spot price and execution price.

Impermanent Loss

Understand the hidden cost of providing liquidity. Compare LP position value vs holding, and see how IL changes with price divergence.

Liquidation Threshold

Watch a position's health factor change as prices move. Visualize collateral value vs debt and see exactly when liquidation occurs.

Concentrated Liquidity

See how narrowing your price range increases capital efficiency (Uniswap v3 style). Compare concentrated vs full-range liquidity.

Seed Phrase Entropy

Visualize why nobody can guess your seed phrase. Pick words one-by-one and watch the combinations grow to astronomical numbers that dwarf atoms in the universe.

Usage

Open any HTML file in a browser. No build step, no dependencies.

Design Principles

  • Single file: Each example is self-contained
  • No dependencies: Works offline
  • Immediate feedback: Every input updates instantly
  • Show the math: Formulas connect visuals to equations

About

Interactive explorations of DeFi concepts

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •  

Languages