Skip to content

rubygitflow/simplest_ruby_framework

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SimplestRubyFramework

SimplestRubyFramework is a little web framework written in Ruby language. It's compatible with Rack interface and intended to learn how web frameworks work in general. This framework is forked from Simpler.

It utilizes '.ERB' templating format for front pages, and offers '.JRB' templating format (i.e. JSON5) for RestApi.

The application overview

SimplestRubyFramework application is a singleton instance of the SimplestRubyFramework::Application class. For convenience it can be obtained by calling SimplestRubyFramework.application method. This instance holds all the routes and responds to call method which is required by the Rack interface.

Install SimplestRubyFramework app

$ cd path/to/the/simplest_ruby_framework/
$ bundle

Run SimplestRubyFramework app

  1. Launch the server
$ rackup

2.Send a request to the app

curl --url "http://localhost:9292" -v
curl --url "http://localhost:9292/tests" -v -X GET
curl --url "http://localhost:9292/tests" -v -X POST
curl --url "http://localhost:9292/tests/0" -v -X GET
curl --url "http://localhost:9292/api/v1/tests" -v -X GET
curl --url "http://localhost:9292/api/v1/health" -v -X GET

About

Handmade Ruby framework

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published