Comment on page
Trustblock labels are visual gateways to display the security state of a project on a website.
- 1.Import the script to your website entry HTML file, as follows:
<script src="https://widget.trustblock.run/audit-label.js" defer />
- 2.Start adding labels anywhere you want on your website:
Each label div must have the
data-tb-audit-labelattribute. Then depending on your use case, It must have either
If you already know the project you want to display the label for and are not in a dynamic context, then you should use
- 1.Head to the project's audit on Trustblock's app, go to the corresponding audit, and get the id from the URL. Eg.
7b9a2b01-bb84-42ca-ac0e-8b70c86debe3is the audit id.
- 2.Then declare your div as follows:
If you don't know the project you want to display the label for and are in a dynamic context, then you should use
- 1.Declare your div as follows:
data-tb-contractaddress: is the address of the contract.
data-tb-chainid: is the chain id of the contract. Below is the list of possible values for
56: Bnb Chain
Optionally, you can add the following attributes with hexadecimal color values to customize the render:
Now it's showing "Not audited" because the filter was set to an address that has not upvoted the auditor who audited this contract.