This section covers the fields in blocklet.yml that define how your blocklet is packaged for distribution and provide essential links to its source code, homepage, documentation, and other resources. Properly configuring these fields is crucial for discoverability, user trust, and integration into the Blocklet ecosystem.
Distribution Package (dist)
The dist object contains information about the blocklet's bundled package. This data is typically generated and added automatically by the blocklet publish command and is used by the Blocklet Store to download and verify the blocklet.
It ensures the integrity and authenticity of the blocklet package that users install.
Schema
- dist
object— Contains information about the blocklet's bundled package.- tarball
string(required) — The URL where the compressed blocklet bundle (.tar.gz) can be downloaded. - integrity
string(required) — A subresource integrity string (e.g., a SHA-512 hash) to verify the downloaded package's contents. - size
number— The size of the tarball in bytes.
- tarball
Example
blocklet.yml
# This field is usually auto-generated during the publish process
dist:
tarball: https://store.blocklet.dev/uploads/z123abc.tar.gz
integrity: sha512-Vbf...Q==
size: 1234567Source Code Repository (repository)
The repository field specifies the location of your blocklet's source code. This is highly recommended as it allows users and contributors to review the code, report issues, and contribute.
You can provide a simple URL string or a more detailed object.
Schema
- repository
string | object— Specifies the location of the blocklet's source code.- type
string(required) — The version control system type (e.g., 'git', 'https', 'svn'). - url
string(required) — The URL of the repository. - directory
string— The path to the blocklet's package within a monorepo.
- type
Example: Simple URL
If you provide a string, it will be automatically parsed to determine the repository type.
blocklet.yml
repository: https://github.com/arcblock/blocklet-spec.gitExample: Object Format
Using the object format is useful for monorepos or when you need to be more explicit.
blocklet.yml
repository:
type: git
url: https://github.com/arcblock/blocklet-framework.git
directory: packages/blocklet-specWeb Links & Support
These fields provide direct links to important external resources, enhancing user support and community engagement.
- homepage
string— The official homepage or marketing page for the blocklet. - documentation
string— A link to the blocklet's detailed documentation site. - community
string— A link to a community forum, Discord server, or other discussion platforms. - support
string— A URL or email address for users to get help.
Example
blocklet.yml
homepage: https://www.arcblock.io/
documentation: https://docs.arcblock.io/
community: https://community.arcblock.io/
support: support@arcblock.ioPromotional Assets
These fields are used to showcase your blocklet in the Blocklet Store, providing users with a visual preview of its features and functionality.
- screenshots
string[]— An array of URLs pointing to images that showcase the blocklet's UI or features. - videos
string[]— An array of up to 3 URLs for promotional videos. Only YouTube and Vimeo links are supported. - logoUrl
string— A direct URL to the blocklet's logo. This is often generated and uploaded by the publishing process.
Example
blocklet.yml
screenshots:
- https://meta.blocklet.dev/screenshots/1.png
- https://meta.blocklet.dev/screenshots/2.png
videos:
- https://www.youtube.com/watch?v=xxxxxxxx
logoUrl: https://meta.blocklet.dev/logo.pngUsage Statistics (stats)
The stats object contains usage metrics for the blocklet. Like the dist field, this is typically managed by the Blocklet Store and should not be set manually.
Schema
- stats
object— Contains usage metrics for the blocklet, managed by the Blocklet Store.- downloads
number— The total number of times the blocklet has been downloaded. - star
number(default:0) — The number of stars or upvotes the blocklet has received. - purchases
number(default:0) — The number of times the blocklet has been purchased.
- downloads
Example
blocklet.yml
# This field is managed by the Blocklet Store
stats:
downloads: 10500
star: 250
purchases: 120With these fields configured, your blocklet is ready for distribution. The next step is to define how it runs.
Next: Execution & Environment
Learn how to configure the blocklet's engine, runtime requirements, environment variables, and startup scripts.
Read More