Aspirerelease/17.0
Watch Aspire live streamsDocsTry Aspire

WithDisplayOrder

Method
📦 Aspire.Hosting v17.0.0
func (Resource) WithDisplayOrder(order float64) Resource

Signature

methodWithDisplayOrderbuilder
Sets the default display order of the resource in lists of resources, such as the dashboard's. A saved ordering takes precedence. Repeated calls replace the order.
WithDisplayOrder(order float64) Resource
orderfloat64A relative sort key. Higher values appear first, consistent with DisplayOrder. Resources without a display order are treated as having an order of 0, so a negative value moves a resource after them.
Resource

The resource builder.

Returns a handle; failures surface later via Err().

Applies to

This method applies to the following types: