-
Notifications
You must be signed in to change notification settings - Fork 322
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/rustasync/tide into cooki…
…e-improvement
- Loading branch information
Showing
5 changed files
with
138 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,115 @@ | ||
# Tide | ||
<h1 align="center">Tide</h1> | ||
<div align="center"> | ||
<strong> | ||
Empowering everyone to build HTTP Services. | ||
</strong> | ||
</div> | ||
|
||
[![build status][1]][2] | ||
<br /> | ||
|
||
An early, experimental web framework. **NOT PRODUCTION-READY**. | ||
<div align="center"> | ||
<!-- Crates version --> | ||
<a href="https://crates.io/crates/tide"> | ||
<img src="https://img.shields.io/crates/v/tide.svg?style=flat-square" | ||
alt="Crates.io version" /> | ||
</a> | ||
<!-- Build Status --> | ||
<a href="https://travis-ci.org/rustasync/tide"> | ||
<img src="https://img.shields.io/travis/rustasync/tide.svg?style=flat-square" | ||
alt="Build Status" /> | ||
</a> | ||
<!-- Downloads --> | ||
<a href="https://crates.io/crates/tide"> | ||
<img src="https://img.shields.io/crates/d/tide.svg?style=flat-square" | ||
alt="Download" /> | ||
</a> | ||
<!-- docs.rs docs --> | ||
<a href="https://docs.rs/tide"> | ||
<img src="https://img.shields.io/badge/docs-latest-blue.svg?style=flat-square" | ||
alt="docs.rs docs" /> | ||
</a> | ||
</div> | ||
|
||
<div align="center"> | ||
<h3> | ||
<a href="https://docs.rs/tide"> | ||
API Docs | ||
</a> | ||
<span> | </span> | ||
<a href="https://github.com/rustasync/tide/blob/master/.github/CONTRIBUTING.md"> | ||
Contributing | ||
</a> | ||
<span> | </span> | ||
<a href="https://discordapp.com/channels/442252698964721669/474974025454452766"> | ||
Chat | ||
</a> | ||
</h3> | ||
</div> | ||
|
||
<div align="center"> | ||
<sub>Built with 🌊 by <a href="https://github.com/rustasync">The Rust Async Ecosystem WG</a> | ||
</div> | ||
|
||
## About | ||
A modular web framework built around async/await. It's actively being developed by the Rust Async | ||
Ecosystem WG, and __not ready for production use yet__. | ||
|
||
## Examples | ||
__Hello World__ | ||
```rust | ||
#![feature(async_await)] | ||
|
||
fn main() -> Result<(), failure::Error> { | ||
let mut app = tide::App::new(()); | ||
app.at("/").get(async move |_| "Hello, world!"); | ||
app.serve("127.0.0.1:8000")?; | ||
} | ||
``` | ||
|
||
__More Examples__ | ||
- [Hello World](https://github.com/rustasync/tide/tree/master/examples/hello.rs) | ||
- [Messages](https://github.com/rustasync/tide/blob/master/examples/messages.rs) | ||
- [Body Types](https://github.com/rustasync/tide/blob/master/examples/body_types.rs) | ||
- [Multipart Form](https://github.com/rustasync/tide/tree/master/examples/multipart-form/main.rs) | ||
- [Catch All](https://github.com/rustasync/tide/tree/master/examples/catch_all.rs) | ||
- [Cookie Extractor](https://github.com/rustasync/tide/tree/master/examples/cookie_extractor.rs) | ||
- [Default Headers](https://github.com/rustasync/tide/tree/master/examples/default_headers.rs) | ||
- [GraphQL](https://github.com/rustasync/tide/tree/master/examples/graphql.rs) | ||
|
||
## Resources | ||
Read about the design here: | ||
|
||
- [Rising Tide: building a modular web framework in the open](https://rustasync.github.io/team/2018/09/11/tide.html) | ||
- [Routing and extraction in Tide: a first sketch](https://rustasync.github.io/team/2018/10/16/tide-routing.html) | ||
- [Middleware in Tide](https://rustasync.github.io/team/2018/11/07/tide-middleware.html) | ||
- [Tide's evolving middleware approach](https://rustasync.github.io/team/2018/11/27/tide-middleware-evolution.html) | ||
|
||
## Contributing | ||
Want to join us? Check out our [The "Contributing" section of the | ||
guide][contributing] and take a look at some of these issues: | ||
|
||
- [Issues labeled "good first issue"][good-first-issue] | ||
- [Issues labeled "help wanted"][help-wanted] | ||
|
||
#### Conduct | ||
The Tide project adheres to the [Contributor Covenant Code of | ||
Conduct](https://github.com/rustasync/tide/blob/master/.github/CODE_OF_CONDUCT.md). This | ||
describes the minimum behavior expected from all contributors. | ||
|
||
## License | ||
Licensed under either of | ||
|
||
* Apache License, Version 2.0 ([LICENSE-APACHE](LICENSE-APACHE) or http://www.apache.org/licenses/LICENSE-2.0) | ||
* MIT license ([LICENSE-MIT](LICENSE-MIT) or http://opensource.org/licenses/MIT) | ||
|
||
at your option. | ||
|
||
[MIT](./LICENSE-MIT) OR [Apache-2.0](./LICENSE-APACHE) | ||
#### Contribution | ||
Unless you explicitly state otherwise, any contribution intentionally submitted | ||
for inclusion in the work by you, as defined in the Apache-2.0 license, shall be | ||
dual licensed as above, without any additional terms or conditions. | ||
|
||
[1]: https://img.shields.io/travis/rustasync/tide.svg?style=flat-square | ||
[2]: https://travis-ci.org/rustasync/tide | ||
[releases]: https://github.com/rustasync/tide/releases | ||
[contributing]: https://github.com/rustasync/tide/blob/master/.github/CONTRIBUTING.md | ||
[good-first-issue]: https://github.com/rustasync/tide/labels/good%20first%20issue | ||
[help-wanted]: https://github.com/rustasync/tide/labels/help%20wanted |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -40,3 +40,5 @@ pub use crate::{ | |
response::Response, | ||
route::Route, | ||
}; | ||
|
||
pub use http; |