The official Flow documentation on NFT views can be found here:

NFT Metadata Views | Flow Developer Portal

In addition we add some extra options to provide a richer experience

Description

In order to start a new line in an NFT description use \n as below

let nftDescription = "First line of the NFT description \\nSecond line begins here"

Levels

We add a ‘Levels’ category which displays as follows:

Screenshot 2024-09-17 at 16.50.26.png

To implement include the below under “traits”

		let levels = {
			"Cuddles":         91.0,
			"Top Wheel Speed": 75.0,
			"Battle Squeak":   89.0,
			"Degen":           69.0,
			"Maximalism":      17.0,
			"Funds are Safu":  75.0

<aside> 💡

The default maximum value is 100

</aside>

Additional Media

We can also add multiple media files with the following:

let medias = {
			"Qmb6mGkxZjQfZTstax4JcXnZ8uD6VL8DR3RYUXykiQ3XZu":"image/gif"
		}

Complete example