Trustless Work
HomeHome

Common Issues#

Common issues and solutions for Trustless Work React blocks.

Answers to Common Questions#

Answers to common questions about Trustless Work React blocks.

Ensure your NEXT_PUBLIC_API_KEY is set in your environment variables.
Provider Order
Make sure providers are nested in the correct order: ReactQueryClientProvider → TrustlessWorkProvider → WalletProvider → EscrowProvider.
Component Imports
If you have import issues, check your .twblocks.json configuration and ensure the uiBase path is correct.
Missing Dependencies
If you are using some blocks, you'll need to check the dependencies section of the block you are using. For example, if you are trying to use the escrows-by-role/table block, you'll need to add the escrow-context, wallet-kit, escrows, handle-errors and helpers block to your project.
Were you unable to use the component due to a lack of data?
If you are using blocks such as change milestone status, start dispute, etc. Maybe you should check if you are using correctly the selectedEscrow and setSelectedEscrowin order to pass the required data to the endpoints.
Server Side Error
When you are using some blocks, you might get a server side error, so you should write "use client" on the top of your component. (Most usually happens with form blocks)
@trustless-work/blocks not installed
Before you add a block, you should install the @trustless-work/blocks package with npm install @trustless-work/blocks.
@trustless-work/blocks not initialized
Before you add a block, you should initialize the @trustless-work/blocks package with npx trustless-work init.

Still have issues? Contact support