Project

mainapp

0.0
No release in over a year
Micro-framework for building applications with data-driven architecture
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

 Project Readme

Mainapp

Gem Version

.set method extracted from the Sinatra::Base, and helper for the components convention

Installation

Add this line to your application's Gemfile:

gem 'mainapp'

And then execute:

$ bundle

Or install it yourself as:

$ gem install mainapp

Usage

Creating structure with components

class My
  extend ::Mainapp::Base
end

My.set foo: 1

My.foo #=> 1

Working with components

class TestComponent
  include ::Mainapp::Component
  attr_struct :foo, :bar

  def some_method
    pp foo
  end
end

components = {foo: 1, bar: 2, baz: 3}
handler = TestComponent.new components

Versioning

See semver.org

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request