Iris, a modular web framework

Iris is a web framework implemented in Go.

I like developing software with Go cause this a really a technology made for our modern world.

Iris is fantastic, in some aspects it remembered me the agility of Django which i love in Python technology and in that, Iris is the best web framework in Go.

Its bests are modularity and efficiency.

Modularity by its ease to split a project with Iris into other sub-project and so doing libraries to re-use. Finally with a well designed project, you can make a web application very quickly by plug-in libraries. Then you can make a really minimalist web project.

Efficiency by using a light engine. The requests respond quickly cause the application has a few software layers to compute. So it’s true that Iris is the fastest web engine among all framework available in Go.

One of the firsts consequence of its modularity is, in my opinion, the way to decorate request routes to add functionality. One example that demonstrate this idea is how we can transform a non-cached request to a cached request. It’s visible in cache example here.

Without cache: app.Get(“/”, writeMarkdown)
With cache: app.Get(“/”, cache.Handler(10*time.Second), writeMarkdown)

Easy, isn’t it? No need to code long module for that or add a function that call a library. We just plug the functionality. And if we want to remove it, no need change the body of the request (writeMarkdown function) !

In summary, with Iris, we could concentrate development on useful parts of a web project: the realization of the web part without thinking of the remaining.