Type of item to create. See the MinecraftItemTypes enumeration for a list of standard item types in Minecraft experiences.
Optionalamount: numberNumber of items to place in the stack, between 1-255. The provided value will be clamped to the item's maximum stack size. Note that certain items can only have one item in the stack.
Number of the items in the stack. Valid values range between 1-255. The provided value will be clamped to the item's maximum stack size.
This property can't be edited in read-only mode.
ReadonlyisGets or sets whether the item is kept on death.
This property can't be edited in read-only mode.
Gets or sets the item's lock mode. The default value is
ItemLockMode.none.
This property can't be edited in read-only mode.
ReadonlymaxOptionalnameGiven name of this stack of items. The name tag is displayed
when hovering over the item. Setting the name tag to an
empty string or undefined will remove the name tag.
This property can't be edited in read-only mode.
ReadonlytypeReadonlytypeThe identifier of the component (e.g., 'minecraft:food') to retrieve. If no namespace prefix is specified, 'minecraft:' is assumed. If the component is not present on the item stack, undefined is returned.
BetaOptionalblockIdentifiers: string[]The list of block types this item can break in Adventure mode. The block names are displayed in the item's tooltip. Setting the value to undefined will clear the list.
This function can't be called in read-only mode.
BetaOptionalblockIdentifiers: string[]The list of block types this item can be placed on in Adventure mode. This is only applicable to block items. The block names are displayed in the item's tooltip. Setting the value to undefined will clear the list.
This function can't be called in read-only mode.
BetaOptionalloreList: string[]Sets the lore value - a secondary display string - for an ItemStack.
This function can't be called in read-only mode.
BetaName of the item type event to trigger. If a namespace is not specified, minecraft: is assumed.
Triggers an item type event. For custom items, a number of events are defined in an items' definition for key item behaviors.
This function can't be called in read-only mode.
Defines a collection of items.