🏠 TypeSOL has a new home on GitHub
Our GitHub account was suspended on Nov 2, most likely by GitHub's automated protection: our CI/CD ran a lot of test runs, merges and releases in a short time. We're not alone here, lately many developers have reported the same on Reddit and GitHub's community forum.
We contacted GitHub Support and haven't heard back yet. Development didn't stop, so we moved everything to a new organization: github.com/typesol-lang
What moved
• typesol, benchmarks and the org profile, with their full history
• All 32 release tags
• typesol.com, the docs and the playground now link to the new home
What didn't change
• npm: same package, the TypeSOL CLI, installs and works as before
• typesol.com and everything on it
Once the original account is restored, the repositories move back to it, and we'll say so here first. If you starred the old repo, a star on the new one helps a lot.
Solana programs can return values, and in TypeSOL that's just a return statement.
An instruction that returns a struct sends it as return data. The calling program reads it back with returnData<Level>(prices): the size has to match the struct and it has to come from the program you named, or the call fails before a single field is read.
It's Anchor's get_return_data with the type attached, and the IDL lists it so the generated client decodes it too.
11
Most compilers grow an intermediate representation early. TypeSOL lowers the checked TypeScript straight to C and lets clang optimize it, and the design review kept it that way.
The reason is one property every release relies on: a program that doesn't use a change compiles to the same binary.
A false refusal is a compile error, never a wrong program. The doc also says what would change the decision: a second backend, or an optimization that pays its way in benchmarks.
Market structure without CU metering, enforced by one read-only account. In this proposal a venue's Fill requires the delay account, and since a taker has to list every account its CPIs touch, every route carries it.
In a TypeSOL program that requirement is one parameter type: Address<AccountInfo, "DELAY…">, read-only and checked before the body runs.
2
63
Where does your Solana program spend its compute?
Build with typesol build --profile and every statement logs its line and the units left. Hand one transaction's logs to typesol profile and you get compute units per TypeScript line, most expensive first, with CPIs counted to the line that made them.
Failures point at your code too: a failed check logs the TypeScript line it came from.
1
1
46
Worth reading before it reaches mainnet.
Two items on that list are refused up front in a TypeSOL program: writing to an account that wasn't passed writable fails the instruction before the write, and account reads are bounds-checked. The guide's LiteSVM route is also the runtime typesol/testing already runs your program in.
Post-Breakpoint feature gate activations are back on the menu today 🧑🍳
Solana devs, direct mapping is a breaking change heading for mainnet activation this cycle.
github.com/anza-xyz/agave/wi…
Creating an account on Solana takes six steps: derive the address, check it, fund the rent, allocate, assign, write the discriminator.
In TypeSOL it's one create call on an Init<T> parameter, and it hands back the bump. InitIfNeeded<T> creates once and checks the account on every call after. Zeroed<T> takes an account the client allocated, up to 10 MiB.
Not every instruction knows its accounts in advance: a route through several pools, a payout to a list of wallets.
In TypeSOL, remainingAccounts() gives you the rest, and loadAccount<T> turns any of them into a checked view, with the same owner, discriminator and size checks a declared Account<T> gets. loadForeign does it for another Anchor program's account, and the whole list spreads straight into a CPI.
1
85
Rust's &mut T, spelled Inout<T>.
A TypeSOL helper that takes Inout<Recorder> gets the caller's struct itself, by pointer, with no copy, and the caller sees every write, the way JavaScript shares an object passed to a function.
The compiler only accepts a writable place there, and refuses any other argument that could reach the same storage during the call.
Every Breakpoint talk is online now, plenty to catch up on.
If one leaves you with an idea for a program, you can write it in TypeScript the same day: typesol.com/play shows what it compiles to, right in the browser, and typesol init sets up a project with tests and a deploy.
A Solana program can read the transaction it runs in. In TypeSOL that's one parameter, ixs: InstructionsSysvar.
Look at the next instruction, check its program and which instruction it is by name, and refuse to run without it: a flash loan can require its repay. stackHeight() === 1n turns away callers that arrive through a CPI.
Every read is bounds-checked. The transaction's author wrote it, so require things of it, never treat it as proof.
Upgrading a Solana program replaces the code, not the data. Every account keeps its old bytes, and the new code reads them with the new struct.
In TypeSOL, Migrate<From, To> rewrites each account as the new struct in one instruction: resized, rent topped up, and stamped with the new discriminator, so it can only migrate once.
Anchor 1.0's Migration, as one parameter type.
Rust's enums with data are one of its best ideas. In TypeSOL you write them the way TypeScript already does: a union of objects, each with a kind.
A switch on kind narrows to the variant, and reading the wrong variant's field fails at run time. Option<T> is just T | null, with === null and ??.
In instruction arguments and events both are Borsh, encoded as Anchor encodes them, so existing clients read them unchanged.
Cheaper storage helps every program, and on Solana a program's own size is storage too: deploying one holds rent for every byte of its binary.
TypeSOL programs start small. The same counter, vault and escrow build to a fraction of their Anchor size, so cheaper rent goes even further.
Breakpoint kept the pace on Day 2. Here’s everything that happened:
- @SolanaFndn became a majority investor in @coingecko
- @anza_xyz CEO @bw_solana revealed that data storage costs on @Solana will drop by 7x within the next two weeks
- @MoonPay’s @PayBox added AI plugins for @PhoenixTrade, @MapleFinance, @MeteoraAG and @fomo
- @temporal_xyz CEO @marcryptonio unveiled perpetuals and options protocols plus an open margin layer coming to Solana next year
- @PhoenixTrade announced plans for a native mobile app and the introduction of @Backpack's tokenized equities as collateral for perps
- @akashnet announced it is building the first forward market for GPU compute on Solana
- @Beezie introduced Mia, a new discovery shopping experience built for women
- @formacity announced a move to Bath to build a new residential campus for founders and a partnership with the University of Bath
- @BitRobotNetwork launched RoboCap Earn, paying users for robotics training data
- @SolanaFndn outlined the future of AI on Solana
- @MetaDAOProject's @metaproph3t highlighted proposed SEC rules letting startups raise up to $5M via token sales
- @X’s Jonathan Lewis demoed Cashtags featuring @fomo and @Collector_Crypt
- @Bitwise presented its 5-year outlook for the Solana ecosystem
- Nasdaq-listed robotics fund @RoboStrategy reported $122M in tokenized $BOT trading volume on Solana, noting 36% occurred while Nasdaq was closed
- @CandyDigital highlighted 1M+ collectors on its app, with ~6M items minted on Metaplex Core
- Solana Breakpoint 2027 announced for San Francisco
Breakpoint 2027 tickets are $50 for a limited time using BP27-VIBHU. See you there.
If you know TypeScript, Solana is mostly seven new words. TypeSOL gives each one a place you already know.
An account is an interface. A program is a file and its exported functions are the instructions. A signer is a parameter type. A PDA is a Seeds type, a call to another program is a method, rent comes back through CloseTo, and every build writes the IDL.
Try it at typesol.com/play.
The fastest way to see TypeSOL: open typesol.com/play.
Pick an example and the compiler runs in your browser. Flip between the C your program compiles to, the Anchor-compatible IDL, and the typed client generated from the same file. Nothing you type leaves the page.
When you're ready to build, test and deploy, typesol init takes it from there.
55
PDAs in TypeSOL read like the rest of your program.
create makes the account at the PDA and hands back the bump to store. A Seeds type checks the address before your code runs, so only the owner's vault gets through. requirePda checks a second one with its stored bump, and signer(seeds) lets the program sign for it in any call.
The IDL records the seeds, so clients derive the same address.
1
50
Calling another program from TypeSOL is a method call.
System, SPL Token, Token-2022, Associated Token, Memo, Stake and Metaplex each get one typed method per instruction. When a PDA vault pays out, pass its seeds as the last argument and the program signs for it. For any other Anchor program, typesol cpi generates typed helpers from its IDL.
No hand-encoded instruction data, and TypeScript checks every argument.
1
99



















