React components for token data

Paste your product key. Ship the stats.

DEV-components are drop-in React components for realtime token charts, fair PNL and holder analytics. No data pipeline to build: add your key and render.

App.jsx3 components, 1 key
import { TokenChart, FairPnl, ExternalHolders }
  from "dev-components";

const key = "YOUR_PRODUCT_KEY";

<TokenChart productKey={key} token={token} />
<FairPnl productKey={key} wallets={wallets} tokens={[token]} />
<ExternalHolders productKey={key} token={token} />

Three components. The numbers you actually need.

Each one is a single tag. Previews below show sample data.

01 <TokenChart />

Realtime token charts

The live chart you know from a trading terminal, built to be embedded. It sizes to its container and sits inside your own layout instead of taking over the page.

  • Streams price updates in realtime
  • Embed-friendly: fits any panel, card or sidebar
  • One prop for the token, one for your key
PEPU / SOLsample data

PEPU / SOL

120 candles from 14:00:00.000 to 14:09:55.000 UTC, price 0.0₇284 to 0.0₇284 SOL, 1251 events. Use the arrow keys to step through candles, Enter to open an own trade of the candle; the event list below has every event.

  • Buy
  • Sell
  • Real: filled
  • Paper / backtest: hollow, dashed
  • Failed: crossed
  • Trigger
  • Pool txs: buys above, sells below the line

02 <FairPnl />

Fair PNL for a group of wallets

Pass a set of wallets and the tokens you care about. You get one PNL figure that already accounts for fees, tips and other costs, so the number matches what actually landed.

  • Aggregates across every wallet in the group
  • Scoped to the tokens you select
  • Fees and tips itemised, not hidden
sample data

Fair PNL

Balances per asset, each in its own units. No USD valuation.
AssetPositionChange since start
SOL3.412871 SOL−0.587129 SOL
PEPUPEPU…pump4,112,908.31 PEPU+4,112,908.31 PEPU
Costs, already included in the SOL change above
CostTransactionsTxsAmount
Tips2−0.002000 SOL
Priority fee3−0.000842 SOL
Fees of failed transactions1−0.000105 SOL
Failed transactions (1)
Time (UTC)Transaction, time and errorErrorFee
14:04:23.3109Roe…nwpq14:04:23.310 UTCProgram error 0x1771: SlippageExceededProgram error 0x1771: SlippageExceeded−0.000105 SOL

03 <ExternalHolders />

External holders, with their PNL

See who holds the token outside your own wallets, and where each of them stands: what they have already realized and what is still on paper.

  • Holders that are not yours, listed per token
  • Unrealized PNL per holder
  • Realized PNL per holder
External holderssample data
External holders: sample data
HolderShareUnrealizedRealized
9aRt…Wm2x4.2%+3.18+1.04
Fh6c…pD8s3.1%−0.74+2.60
2nVy…Jq4e2.7%+1.920.00
Ks8b…u7Hg1.9%−0.35−0.48

Set up in three steps

  1. Step 1

    Install the package

    Add DEV-components to your React project.

    npm install dev-components
  2. Step 2

    Add your product key

    The key is the only configuration. There is no backend to host and no indexer to run.

    productKey="YOUR_PRODUCT_KEY"
  3. Step 3

    Render the component

    Point it at a token or a group of wallets. The data arrives live.

    <TokenChart token={token} />

Built to sit on top of your own scripts

You already have the scripts that do the work. DEV-components adds the stats layer, so you can see what those scripts are doing without building the analytics yourself.

  • Custom script dashboards

    Put a live chart next to the controls of the script that trades it.

  • Multi-wallet setups

    Track the whole wallet group as one position, with costs included.

  • Knowing the other side

    Check how outside holders are positioned before your script makes its next move.

One key. Three components. Real numbers.

Get your product key and have the first chart rendering today. Pricing: [YOUR PRICE].

Get a product keyplaceholderRead the docsplaceholder
DEV-componentsPreview panels on this page show sample data.[YOUR CONTACT]placeholder

Stage 7

PnL module and components

divers-pnl is the toolkit's only PnL calculation: backtest, paper trading and post-trade give comparable numbers. The React components are parts of the same UI, shipped as a separate package.

Stage
PnL module and components
Command or package
Rust crate divers-pnl and an npm package
Indexer
not required
State
works divers-pnl and the components are built and covered by tests. The npm package name is temporary.

DEV-components today

The landing above describes the DEV-components product. This is what the package does today and what is still planned.

Available now

  • Package @divers-placeholder/components (temporary name), used from this repository's workspace.
  • Data comes in through props: the components make no requests and compute nothing. There is no product key.
  • CandleChart: static candles with events; no realtime streaming.
  • PnlTable: positions, changes and costs.
  • HolderLevels and TokenInfo.
  • Race components: RaceTimeline, RaceTable, ValidatorCard, ValidatorPair.
  • Predicted price improvement: PpiCell, PpiDetail, PpiSummary.
  • Themed through the --odv-* tokens, light and dark.

Planned

  • A product key and hosted data (productKey).
  • Realtime price streaming.
  • <TokenChart>, <FairPnl> and <ExternalHolders>; the closest today are CandleChart, PnlTable and HolderLevels.
  • Install with npm install dev-components; the package is not published under that name.

What it is

divers-pnl

A Rust crate in the shared workspace. Input: a journal of transactions with SOL and token balances before and after, in one format for backtest, paper trading and real trades; no instruction parsing is needed. Output: two lists per asset: positions ("+53 coin, 3 SOL") and changes since the start of the session ("−32 coin4, +1 SOL").

Every cost is already inside the SOL balance change; tips and priority fees are shown on separate lines, failed transactions by their fee.

Components

  • CandleChart: a candle chart with events: entries and exits (real or virtual), neighbouring transactions, triggers.
  • PnlTable: positions, changes and costs.
  • RaceTimeline: the race: trigger, transactions that got ahead, execution.
  • ValidatorCard, ValidatorPair: the validator card.
Sample: a component package fixture, not the result of a runThe package's live components on its synthetic fixtures: the pool, wallets and validators are made up.

Candle chart with events

120 candles from 14:00:00.000 to 14:09:55.000 UTC, price 0.0₇284 to 0.0₇284 SOL, 1251 events. Use the arrow keys to step through candles, Enter to open an own trade of the candle; the event list below has every event.

  • Buy
  • Sell
  • Real: filled
  • Paper / backtest: hollow, dashed
  • Failed: crossed
  • Trigger
  • Pool txs: buys above, sells below the line
Event list (1251)

Positions and PnL

Balances per asset, each in its own units. No USD valuation.
AssetPositionChange since start
SOL3.412871 SOL−0.587129 SOL
PEPUPEPU…pump4,112,908.31 PEPU+4,112,908.31 PEPU
Costs, already included in the SOL change above
CostTransactionsTxsAmount
Tips2−0.002000 SOL
Priority fee3−0.000842 SOL
Fees of failed transactions1−0.000105 SOL
Failed transactions (1)
Time (UTC)Transaction, time and errorErrorFee
14:04:23.3109Roe…nwpq14:04:23.310 UTCProgram error 0x1771: SlippageExceededProgram error 0x1771: SlippageExceeded−0.000105 SOL

Race timeline

2 transactions got in ahead; the first by 6.535 ms.

From the trigger to your transaction: 418.846 ms

View:

Slot start and end times are not known for this window: each row shows the order in the block, not time.

slot 381204331slot 3812043311 of this coinslot 381204332slot 3812043323 of this coinTriggerours
buysellfailedGlyph size: priority fee:0.000310 SOL0.000281 SOLzero (hollow)Circle below: tip (size) and landing service (colour):0.004000 SOL0.002500 SOLLanding services:Jitoyour transaction

Execution validatorFjord Nodes

Identity
ExeCVa…vBnM7q
Client
Harmonic
Country
NL · Netherlands
Provider
Teraswitch
IP
198.51.100.7
Slot
381204332
Vote account
VoTeFj…tLuE4o

What it gives traders and quants

  • The same PnL on history, in paper trading and for real trades: differences between them do not come from different formulas.
  • Components with no tie to our API: data through props, no requests and no calculations inside. You can embed them in your own dashboard; our app is built from the same package.
  • Styling through theme tokens (--odv-* CSS variables), light and dark themes. This site is built on the same tokens.

How to run

Journal PnL from the CLI
divers sim report run.jsonl        # positions, changes, costs
Components in React
import { CandleChart, PnlTable } from "@divers-placeholder/components";
import "@divers-placeholder/components/styles.css";

<PnlTable positions={positions} changes={changes} costs={costs} />

The package name @divers-placeholder/components is temporary.

divers-pnl is used as a library from the workspace, without the CLI. The UI components always take their numbers from the backend: there is no WASM build of the calculation.

Limitations

  • The first version has no USD conversion and no valuation of open positions: each asset is in its own units.
  • The list of tip provider addresses holds only Jito addresses for now; the report marks it as incomplete.
  • The npm package name is temporary; the props are still being aligned with the output of divers-pnl.
  • The chart has no zoom, no scrolling and no tooltip on markers. Labels default to English; a translation is set with the DiversLabels provider or the labels prop.

Place in the chain

Input
Journals of the backtest and paper trading, trades of post-trade analysis.
Output
Positions, changes and costs, and the components that show them. End of the chain.