npm install
First, run the development server:
npm run dev
# or
yarn dev
npm run start-devnet // this will start a devnet for smart contract tests
npm run stop-devnet
npm run restart-devnet
npm run test:contracts
or
npm run test:contracts -- nft-marketplace.test.ts
Before running the application, two smart contracts need to be created:
- A marketplace smart contract where NFTs can be traded
- A default NFT collection smart contract, which will be the default collection for NFTs that do not explicitly belong to any NFT collections
npm run deploy:contracts
There are two environments available during development:
development-nodewallet
and browser-extension
as configured
in alephium-configs.ts. In
development-nodewallet
environment, node wallet is used as signer
for authentication and signing transactions. In
browser-extension
environment Wallet Connect is used
instead.
development-nodewallet
is the default environment. To switch
environment, update the ENVIRONMENT
variable in
next.config.js file.