typink
v0.6.0
Published
Fully-typed react hooks to interact with ink! smart contract powered by Dedot!
Readme
Typink
The ultimate toolkit for dapps development on Polkadot, powered by Dedot!
Typink is a fully type-safe React hooks library for seamless ink! and Solidity smart contract interactions. It supports both WASM (pallet-contracts) and PolkaVM (pallet-revive) on Polkadot, delivering robust, efficient, and developer-friendly dapps development.
👉 Join our Telegram group to receive the latest updates and support!! 👈
Why Typink?
- ✅ Unified Type-Safe Hooks - Same React hooks work seamlessly across ink!, and Solidity contracts.
- ✅ Instant Project Scaffolding - Launch new projects in seconds with create-typink CLI and pre-configured Next.js templates
- ✅ Flexible Wallet Connector Integration - Supports external wallet connectors like SubConnect, Talisman Connect, LunoKit or built your own using Typink's hooks & API.
- ✅ Multi-Network Support - Connect to multiple networks simultaneously with lazy initialization and seamless network switching
Quick look
Getting started
Start a new project from scratch via create-typink cli
Typink comes with a cli to help you start a new project from scratch faster & easier, to create a new project, run the below command:
# pnpm
pnpm create typink@latest
# yarn
yarn create typink@latest
# npm
npm create typink@latest
# bun
bunx create-typink@latest[!IMPORTANT] The
create-typinkcli requires NodeJS version >=v20to work properly, make sure to check your NodeJS version.
Following the instructions, the cli will help you generate a starter & working project ready for you to start integrate your own contracts and build your own logic. Checkout the getting started guide for more details.
Migrate from existing projects?
Install typink & dedot packages:
# via npm
npm i typink dedot
# via yarn
yarn add typink dedot
# via pnpm
pnpm add typink dedotTypink heavily uses Typescript to enable & ensure type-safety, so we recommend using Typescript for your Dapp project. Typink will also work with plain Javascript, but you don't get the auto-completion & suggestions when interacting with your ink! contracts. Checkout Typink's migration guide.
Documentation
Check out Typink documentation on our website: https://typink.dev
- Getting started
- Migrate from existing project
- Hooks & Providers
- Utilities
- Tutorial: Build a PSP22 Transfer with Typink
Example Dapps
- Demo (https://typink-demo.netlify.app/)
- Demo with SubConnect (https://typink-subconnect.netlify.app/)
- Demo with LunoKit (https://typink-lunokit.netlify.app/)
License
Acknowledgements
Funded by W3F
