目录
目录README.md

示例

基础示例

  • hello world cargo run --bin hello
  • route cargo run --bin route 路由配置
  • body cargo run --bin body 解析请求体
  • header cargo run --bin header 解析请求头
  • rejections cargo run --bin rejections 错误处理
  • futures cargo run --bin futures 异步操作
  • todo cargo run --bin todo TODO App

文件服务器

  • files cargo run --bin file
  • dir cargo run --bin dir
  • HTML cargo run --bin handlebars_template HTML 模板

Websockets

  • Websocket cargo run --bin ws
  • Websocket_chart cargo run --bin ws_chart ws App

SSE(server Side Events)

  • sse cargo run --bin sse
  • sse_chat cargo run --bin sse_chat sse App

TLS

  • tls cargo run --bin tls

热更新

  • autoreload systemfd --no-pid -s http::3030 -- cargo watch -x 'run --bin autoreload'

调试

  • tracing cargo run --bin tracing
关于

warp 示例

90.0 KB
邀请码
    Gitlink(确实开源)
  • 加入我们
  • 官网邮箱:gitlink@ccf.org.cn
  • QQ群
  • QQ群
  • 公众号
  • 公众号

©Copyright 2023 CCF 开源发展委员会
Powered by Trustie& IntelliDE 京ICP备13000930号