henriette
henriette
Avram generates the Operation and the Query classes from macros ran in Model. This means that we don't have the ability to reference other models to handle certain association logic. It also creates magic code.
Installation
-
Add the dependency to your
shard.yml
:dependencies: henriette: github: matthewmcgarvey/henriette
-
Run
shards install
Usage (WIP)
require "henriette"
Models
class User < Henriette::Model
primary_key id : Int64
column created_at : Time
column updated_at : Time
column name : String
has_many credentials : Array(Credential)
end
Queries
class UserQuery < Henriette::Query(User)
connect_to User
end
Operations
class SaveUser < Henriette::Operation
connect_to User
end
Development
TODO: Write development instructions here
Contributing
- Fork it (https://github.com/matthewmcgarvey/henriette/fork)
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create a new Pull Request
Contributors
- Matthew McGarvey - creator and maintainer
Repository
henriette
Owner
Statistic
- 0
- 0
- 0
- 0
- 2
- about 4 years ago
- October 24, 2020
License
MIT License
Links
Synced at
Thu, 07 Nov 2024 10:22:27 GMT
Languages