Developer preview. Vela, Facet, and Quire are pre-release and in active development — syntax, APIs, and availability may change, and they are not yet generally available.
SStretch Dev Docs
Quire

Commerce Schema

Built-in commerce roots, identifiers, cart fields, and declarative commerce capabilities.

Quire includes a built-in StretchShop-oriented commerce schema. Project-generated schemas can extend or overwrite this model through the live schema contract.

Commerce support is compile-time validation plus declarative IR output. Quire does not perform cart mutation, checkout, inventory lookup, or storefront navigation.

Built-in roots

The built-in commerce model includes:

  • Product
  • Variant
  • Collection
  • Cart
  • CartLine
  • Customer
  • Address
  • Inventory
  • Discount

Identifier primitives include ProductID, VariantID, CartID, LineItemID, CustomerID, AddressID, InventoryID, and DiscountID. Money remains a primitive value type resolved by the renderer, theme, or runtime layer.

Product views

Product and variant fields cover merchandising, inventory, price, images, options, default variants, discounts, and collection relationships.

From examples/product.quire:

quire ProductPage {
  model {
    product: Product
    cart: Cart
  }

  route "/products/{product.slug}"
  title product.title

  section hero {
    text eyebrow {
      value product.collection.title
      variant "eyebrow"
    }

    text heading {
      value product.title
      variant "display"
    }

    image productMedia {
      src product.featuredImage.url
      alt product.title
    }

    price currentPrice {
      value product.price
    }

Cart actions

Commerce capabilities compile to declarative Action descriptors. Built-in capabilities include cart add, quantity update, remove, clear, view, checkout open, collection open, discount apply/remove, and product open.

From examples/product.quire:

    if product.available {
      button addToCart {
        label "Add to cart"
        action commerce.cart.add(product.defaultVariant.id)
      }
    }

From starters/store/components.quire:

    region cartSummary {
      stack cartLine {
        gap token("space.inline.sm")

        text cartLabel {
          value "Cart subtotal"
          variant token("type.caption")
        }

        price subtotal {
          value cart.subtotal
          variant token("type.price.caption")
        }
      }
    }

Runtime responsibility

The runtime or render engine must honor only the capabilities exposed through its registry. Project schemas can add capabilities, but Quire compiles them as descriptors rather than executable behavior.