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.
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.
$ cd path/to/the/simplest_ruby_framework/
$ bundle
- 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