Solana Boilerplate - Lightweight boilerplate for Solana dapps. Allows quick building and prototyping.

Overview

Solana Boilerplate

Lightweight boilerplate for Solana dapps. Allows quick building and prototyping.

⭐️ Star us

If this repo helps you building your dapps on Solana - please ensure you leave us a star! This motivates and helps us a lot to bring more free code, templates and boilerplates to you.

🤝 Need help?

If you need help with setting up the boilerplate or have other questions - don't hesitate to write in our community forum and we will check asap. Forum link. The best thing about this boilerplate is the super active community ready to help at any time! We help each other.

🚀 Quick Start

📄 Clone or fork solana-boilerplate:

git clone https://github.com/solana-boilerplate/solana-boilerplate.git

💿 Install all dependencies:

cd solana-boilerplate
yarn install 

Rename .env.example to .env in the main folder and provide your appId and serverUrl from Moralis (How to start Moralis Server) Example:

REACT_APP_MORALIS_APPLICATION_ID=xxxxxxxxxxxx
REACT_APP_MORALIS_SERVER_URL=https://xxxxxx.grandmoralis.com:2053/server

🚴‍♂️ Run your App:

yarn start

🧭 Table of contents

🏗 Solana Components

🧰 Solana Hooks

useSolana

Gets basic Solana information such as user's address.

Example

const { account } = useSolana();

useSolanaNativeTokenBalance

Gets Solana SOL token balance of an address.

Example

const { getSolanaNativeBalance, data, error, isLoading } = useSolanaNativeTokenBalance({
  network: "mainnet",
  address: "xxx"
});

useSPLTokenBalance

Gets Solana SPL token balance of an address.

Example

const { getSPLTokenBalance, data, error, isLoading } = useSPLTokenBalance({
  network: "mainnet",
  address: "xxx"
});

useSPLNFTBalance

Gets Solana NFT balance of an address.

Example

const { getSPLNFTBalance, data, error, isLoading } = useSPLNFTBalance({
  network: "mainnet",
  address: "xxx"
});

useSolanaPortfolio

Gets Solana portfolio (SOL, SPL token, SPL NFT) of an address.

Example

const { getSolanaPortfolio, data, error, isLoading } = useSolanaPortfolio({
  network: "mainnet",
  address: "xxx"
});
You might also like...

An upgradable boilerplate for Progressive web applications (PWA) with server side rendering, build with SEO in mind and achieving max page speed and optimized user experience.

An upgradable boilerplate for Progressive web applications (PWA) with server side rendering, build with SEO in mind and achieving max page speed and optimized user experience.

React PWA v2 A highly scalable, Progressive Web Application foundation,boilerplate, with the best Developer Experience. Demo: https://demo.reactpwa.co

Dec 26, 2022

🚀 A well-structured boilerplate and Starter for Next.js 12+, Tailwind CSS 3, Redux, Redux Thunk, and TypeScript

🚀 A well-structured boilerplate and Starter for Next.js 12+, Tailwind CSS 3, Redux, Redux Thunk, and TypeScript ⚡️ Made with developer experience first ESLint + Prettier + Lint-Staged + VSCode setup

Nov 28, 2022

A default Next.js project with boilerplate packages and configurations. Includes Tailwind, TypeScript (strict), ESLint, Prettier, and Husky.

Yet another Next.js project template This template includes a set of our favorite dev tools scaffolded into a Next.js project. Tools include: TypeScri

Dec 27, 2022

React + Redux starter kit / boilerplate with Babel, hot reloading, testing, linting and a working example app built in

React + Redux starter kit / boilerplate with Babel, hot reloading, testing, linting and a working example app built in

A comprehensive starter kit for rapid application development using React. Why Slingshot? One command to get started - Type npm start to start develop

Jan 3, 2023

NextJS, TypeScript and Styled Components project boilerplate

This is a Next.js project bootstrapped with create-next-app. Getting Started First, run the development server: npm run dev # or yarn dev Open http://

Sep 21, 2021

Next Boilerplate with TypeScript, Redux Toolkit and Styled-Component.. For now

This is a Next.js project bootstrapped with create-next-app. Getting Started First, run the development server: npm run dev # or yarn dev Open http://

Feb 17, 2022

Boilerplate for HTML, CSS, JS and TailwindCSS

tailwind-vanillajs-boilerplate 🔨 Boilerplate for HTML, CSS, JS and TailwindCSS

Aug 10, 2022

Next Boilerplate was created to be a template for starting NextJS projects with pre-configured settings like Linters, Test Setup, Storybook and Commit Hooks.

Next Boilerplate was created to be a template for starting NextJS projects with pre-configured settings like Linters, Test Setup, Storybook and Commit Hooks.

Next Boilerplate was created to be a template for starting NextJS projects with pre-configured settings like Linters, Test Setup, Storybook and Commit Hooks.

Feb 22, 2022

This is a minimal Next-Js boilerplate for TypeScript and Tailwind.

This is a Next.js project bootstrapped with create-next-app. Getting Started First, run the development server: npm run dev # or yarn dev Open http://

Sep 15, 2022
Owner
null
A boilerplate application for building Node.js back-end application in TypeScript

RESTful API Node Server Boilerplate A boilerplate/starter project for quickly building RESTful APIs and with typescript ?? Installation Install the de

Youssef Hajjari 14 Nov 23, 2022
React Native Boilerplate - The Boilerplate contains all the basic packages, common components and, prebuilt code architecture

The Boilerplate contains all the basic packages, common components and, prebuilt code architecture. It will save developer's project setup time.

MindInventory 36 Dec 26, 2022
NodeJS library develop quick start: TypeScript + CI/CD + Release Workflow + Linter + Changelog + ...

node-lib-starter Start NodeJS + TypeScript library developing with ease, have fun! Include Lint Git Hooks Release workflow CI/CD Changelog Configurati

LinbuduLab 22 Oct 28, 2022
IDE and toolkit for building scalable web applications with React, Redux and React-router

An all-in-one solution for creating modern React apps Rekit is a toolkit for building scalable web applications with React, Redux and React-router. It

Rekit 4.5k Jan 2, 2023
A professional front-end template for building fast, robust, and adaptable web apps or sites.

HTML5 Boilerplate HTML5 Boilerplate is a professional front-end template for building fast, robust, and adaptable web apps or sites. This project is t

H5BP 53.8k Dec 28, 2022
An experiment in building a public facing personal knowledge web app with TiddlyWiki and Nodejs.

Maarfapad What is this? Maarfapad was my attempt at learning Expressjs back in 2016 while building a CRUD app to handle TiddlyWiki html files. It was

A.B. Samma 3 Mar 12, 2022
Webplate is an awesome front-end framework that lets you stay focused on building your site or app all the while remaining really easy to use.

Webplate Framework Webplate is an awesome front-end framework that lets you stay focused on building your site or app all the while remaining really e

Chris Humboldt 560 Nov 24, 2022
A simple environment to start building on Starknet with Cairo

Starknet Boilerplate A simple environment to start building on Starknet with Cairo. Uses Nile for compilation/deployment and Starknetjs for contract i

threepwave 19 Dec 11, 2022
Node Express Template (NET.ts) - a small template project which help you to speed up the process of building RESTful API

Node Express Template (NET.ts) - a small template project which help you to speed up the process of building RESTful API

Przemek Nowicki 26 Jan 4, 2023
Opinionated SvelteKit Template for building web applications.

Opinionated SvelteKit Template for building web applications.

Manassarn 7 Jan 1, 2023