Code Monkey home page Code Monkey logo

forgery2's Introduction

forgery2

Build Status

UNSTABLE VERSION 2.0: The current stable version is here forgery

Forgery is a minimal and flexible golang web application framework, providing a robust set of features for building single and multi-page, web applications.

  • Robust routing
  • HTTP helpers (redirection, caching, etc)
  • View system supporting 1 template engine (hopefully more will come)
  • Content negotiation
  • Focus on high performance
  • Environment based configuration
  • High test coverage

Install

go get github.com/goforgery/forgery2

Use

Starts a web server.

package main

import(
    "github.com/goforgery/forgery2"
)

func main() {
    app := f.CreateApp()
    app.Get("/", func(req *f.Request, res *f.Response, next func()) {
        res.Send("Hello world.")
    })
    app.Listen(3000)
}

Testing

go test ./...

Code Coverage

go test -coverprofile=coverage.out; go tool cover -html=coverage.out -o=coverage.html
open coverage.html

Benchmark

go test -bench=. -run=BENCH_ONLY

Notes

This project started out as a clone of the superb Node.js library Express.

forgery2's People

Watchers

James Cloos avatar ratnesh singh avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.