On Chain
Deploying on-chain project

Effectively in case of on-chain project you simply need to associate files with already deployed contract. So, before proceeding this current guide make sure you have deployed a contract as described here.
- Go to contracts on-chain management page
- Select you contract in drop-down
- There are two tabs: "Files" and "Metadata"
- In "Files" tab, drag and drop all files an click "Add files". This will invoke multiple transactions, you should approve them all.
- You can minify source files, but there is no need to compress them — this will be handled by the system;
- If your project contains dependencies (e.g. external js libraries), refer to "Managing dependencies" section of current document;
- Verify that your wallet has sufficient gas!
- Generally consider double-checking final set of files with Verse engineering team before upload;
- In "Metadata" tab, you can set additional metadata that will be stored on-chain. After clicking "Save" you will have to accept transaction(s) as well.
Managing dependencies
Even though it's possible to upload a large dependency file altogether with other sources, it's more convenient (and cheap)
to store some reference to dependency instead. You can put a special file with name dependencies.json
that will be
treated specially with the system (actual JSON schema can be found in GitHub repo):
[
{
"alias": "p5@1.9.0",
"licenseType": "LGPL-2.1-only",
"name": "p5.js",
"version": "1.9.0",
"filePath": "p5.min.js"
}
]
You can check motivation on this particular approach here.
Re-building project from on-chain
To actually re-build Verse project fully "from chain", you can use this tool maintained by Verse.