dojo-setup

Configure the Dojo.js SDK with world address and Torii URL.

37|54|Updated Sep 11, 2023
One-click install
npx skills add https://github.com/dojoengine/dojo.js --skill dojo-setup
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: dojo-setup
Source: https://github.com/dojoengine/dojo.js/tree/main/.claude/skills/dojo-setup
Command: npx skills add https://github.com/dojoengine/dojo.js --skill dojo-setup

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This skill helps frontend developers bootstrap and configure the Dojo.js SDK for a production-ready frontend, including world address and Torii configuration and establishing the React provider tree for contract calls.

Core Features & Use Cases

  • SDK Initialization: create an SDK instance with the world address and Torii URL, and optionally a manifest for ABIs to enable type-safe calls.
  • React Provider Setup: wrap your application with DojoSdkProvider to supply the Dojo config and ensure proper provider hierarchy.
  • Environment & Type Safety: leverage environment variables and generated TypeScript types from ABIs for robust integration.

Quick Start

Configure the Dojo.js SDK in your frontend project by supplying the world address and torii URL, and wrap your app with DojoSdkProvider to initialize the SDK.

Frequently Asked Questions about dojo-setup

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I configure the Dojo.js SDK in my React frontend?

To configure the Dojo.js SDK in your React frontend, you initialize an SDK instance with your world address and Torii URL, then wrap your application with DojoSdkProvider to establish the provider tree for contract calls.

What is the Dojo provider used for in frontend development?

The Dojo provider supplies the Dojo configuration to your React application and establishes the correct provider hierarchy, enabling type-safe contract calls and interactions with a Dojo world.

Do I need a manifest or ABIs to set up the Dojo.js SDK?

A manifest or ABIs are optional for the Dojo.js SDK setup, but providing them enables generated TypeScript types for robust, type-safe contract integration within your frontend project.

How do I initialize the Dojo SDK with a world address and Torii URL?

You initialize the Dojo SDK by supplying the required worldAddress and toriiUrl parameters to create an SDK instance, which wires the provider correctly to access your Dojo world.

Can I use environment variables for Dojo SDK configuration?

Yes, you can leverage environment variables to manage your world address and Torii URL configuration, ensuring robust integration and secure setup for the Dojo.js SDK in your frontend project.

What's the best way to bootstrap Dojo.js for a new frontend project?

The best way to bootstrap Dojo.js is to configure the SDK instance with the world address and Torii URL, then wrap your app with DojoSdkProvider to initialize the SDK and ensure proper provider hierarchy.