mirror of
https://github.com/kataras/iris.git
synced 2025-03-21 14:56:26 +01:00
minor: README
This commit is contained in:
parent
7e5469f3d1
commit
0372b95fb3
65
README.md
65
README.md
|
@ -13,7 +13,7 @@
|
|||
|
||||
# Iris Web Framework <a href="README_GR.md"><img width="20px" src="https://iris-go.com/images/flag-greece.svg" /></a> <a href="README_FR.md"><img width="20px" src="https://iris-go.com/images/flag-france.svg" /></a> <a href="README_ZH.md"><img width="20px" src="https://iris-go.com/images/flag-china.svg" /></a> <a href="README_ES.md"><img width="20px" src="https://iris-go.com/images/flag-spain.png" /></a> <a href="README_FA.md"><img width="20px" src="https://iris-go.com/images/flag-iran.svg" /></a> <a href="README_RU.md"><img width="20px" src="https://iris-go.com/images/flag-russia.svg" /></a> <a href="README_KO.md"><img width="20px" src="https://iris-go.com/images/flag-south-korea.svg?v=12" /></a>
|
||||
|
||||
[](https://github.com/kataras/iris/actions) [](https://github.com/kataras/iris/tree/master/_examples) [](https://gitter.im/iris_go/community) <!--[](https://app.fossa.io/projects/git%2Bgithub.com%2Fkataras%2Firis?ref=badge_shield)--> [](https://iris-go.com/donate) <!--[](https://goreportcard.com/report/github.com/kataras/iris)--><!--[](https://pkg.go.dev/github.com/kataras/iris/v12@v12.2.0)--> <!-- [](https://github.com/kataras/iris/releases) -->
|
||||
[](https://github.com/kataras/iris/actions) [](https://github.com/kataras/iris/tree/master/_examples) [](https://gitter.im/iris_go/community) <!--[](https://app.fossa.io/projects/git%2Bgithub.com%2Fkataras%2Firis?ref=badge_shield)--> [](https://iris-go.com/donate) <!--[](https://goreportcard.com/report/github.com/kataras/iris)--><!--[](https://pkg.go.dev/github.com/kataras/iris/v12@v12.2.0)--> <!-- [](https://github.com/kataras/iris/releases) -->
|
||||
|
||||
<!-- <a href="https://iris-go.com"> <img align="right" src="https://iris-go.com/images/logo-w169.png"></a> -->
|
||||
|
||||
|
@ -38,36 +38,6 @@ func main() {
|
|||
}
|
||||
```
|
||||
|
||||
<details><summary>API Guide</summary>
|
||||
|
||||
```go
|
||||
package main
|
||||
|
||||
import (
|
||||
// [other packages...]
|
||||
|
||||
"github.com/kataras/iris/v12"
|
||||
)
|
||||
|
||||
func main() {
|
||||
app := iris.NewGuide().
|
||||
AllowOrigin("*").
|
||||
Compression(true).
|
||||
Health(true, "development", "kataras").
|
||||
Timeout(0, 20*time.Second, 20*time.Second).
|
||||
Middlewares(basicauth.New(...)).
|
||||
Services(
|
||||
// NewDatabase(),
|
||||
// NewPostgresRepositoryRegistry,
|
||||
// NewUserService,
|
||||
).
|
||||
API("/users", new(UsersAPI)).
|
||||
Listen(":80")
|
||||
}
|
||||
```
|
||||
|
||||
</details>
|
||||
|
||||
<details><summary>More with simple Handler</summary>
|
||||
|
||||
```go
|
||||
|
@ -176,6 +146,37 @@ Want to see more? Navigate through [mvc examples](_examples/mvc)!
|
|||
</details>
|
||||
|
||||
|
||||
<details><summary>API Guide <strong>HOT</strong></summary>
|
||||
|
||||
```go
|
||||
package main
|
||||
|
||||
import (
|
||||
// [other packages...]
|
||||
|
||||
"github.com/kataras/iris/v12"
|
||||
)
|
||||
|
||||
func main() {
|
||||
app := iris.NewGuide().
|
||||
AllowOrigin("*").
|
||||
Compression(true).
|
||||
Health(true, "development", "kataras").
|
||||
Timeout(0, 20*time.Second, 20*time.Second).
|
||||
Middlewares(basicauth.New(...)).
|
||||
Services(
|
||||
// NewDatabase(),
|
||||
// NewPostgresRepositoryRegistry,
|
||||
// NewUserService,
|
||||
).
|
||||
API("/users", new(UsersAPI)).
|
||||
Listen(":80")
|
||||
}
|
||||
```
|
||||
|
||||
</details>
|
||||
|
||||
<br/>
|
||||
|
||||
Learn what [others saying about Iris](https://www.iris-go.com/#review) and **[star](https://github.com/kataras/iris/stargazers)** this open-source project to support its potentials.
|
||||
|
||||
|
@ -430,7 +431,7 @@ For a more detailed technical documentation you can head over to our [godocs](ht
|
|||
|
||||
[](https://twitter.com/intent/follow?screen_name=iris_framework)
|
||||
|
||||
[](https://www.facebook.com/iris.framework)
|
||||
[](https://www.facebook.com/iris.framework)
|
||||
|
||||
You can [request](https://www.iris-go.com/#ebookDonateForm) a PDF and online access of the **Iris E-Book** (New Edition, **future v12.2.0+**) today and be participated in the development of Iris.
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user