Attribute Macro worker_route::delete

source ·
#[delete]
Expand description

A macro that creates route handler with worker::Router::delete_async.

Usage

 #[delete("path")]

Attributes

  • "path": Worker’s path.

Examples

use worker::{Result, Response};
use worker_route::delete;

#[delete("/path")]
async fn foo() -> Result<Response>{
    Response::empty()
}