# useApplyDocumentActions https://www.sanity.io/learn/course/build-content-apps-with-sanity-app-sdk/use-apply-document-actions.md Perform actions on documents to end—or begin—the content lifecycle Document Actions are primarily used to modify the "version" of an entire document—to publish a draft document, to discard the current draft, or to delete the document. In our app it may be useful to delete feedback that we don't want to keep (this is different from spam where we may want to keep it as a record of a sender for who all future submissions should be blocked). ## Delete document action 1. **Create** a new component to hold all our document actions. ```tsx:app-feedback/src/Actions.tsx import { deleteDocument, type DocumentHandle, useApplyDocumentActions, } from "@sanity/sdk-react" import { Button, Flex } from "@sanity/ui" type ActionsProps = { handle: DocumentHandle } export function Actions({ handle }: ActionsProps) { const apply = useApplyDocumentActions() const handleDelete = () => apply(deleteDocument(handle)) return (