controller
controller copied to clipboard
Complete, fast and testable actions for Rack and Hanami
In hanami-controller 1.3.x, we have the following **public class methods** available inside `Hanami::Action` subclasses: - `before`, `append_before`, `prepend_before`, `after`, `append_after`, `prepend_after` (via the `Action::Callbacks` module) - `expose` (via `Action::Exposable`) -...
This fixes some things in YARD docs. More of a housekeeping than storytelling - I focused on minor things like: * Making sure links in @see work * Transforming all...
# Enhancement Re-establish `Hanami::Action#call` as Public API for Hanami 2.0 actions. During the Hanami 2.0 rewriting, we had to gave up to a _Hanami signature_ method `#call` for actions in...
Somewhat unhappy with the implementation, but this introduces some tests as well on which we can rely on to refactor this. Feel free to suggest improvements, maybe we could leverage...
Branched off from the work at https://github.com/hanami/controller/pull/379
When trying out the hanami 2 application template and using the `params` class method in an action I faced the issue that non-whitelisted params were accessible through `req.params.to_h`. This is...
When I launch Hanami 2 template, it complains about CSP rules and doesn't load styles and script files. I've found that `"\n"` separator used for converting CSP configuration to header...
Before: ```ruby view = nil response.render(view) # #
https://github.com/hanami/hanami-2-application-template/commit/9a23a1b331dc0ee7629099d0d6320a3f341e4885 [crashes](https://gist.github.com/jodosha/99254d58c7e7432830184dc5d4bc5085) when I try to run the specs: --- The [current implementation](https://github.com/hanami/controller/blob/d59d5b6eda2fa5229f4291bb503c031abd31899e/lib/hanami/action/configuration.rb#L408-L411) of `Hanami::Action::Configuration#public_directory` is: ```ruby def public_directory root_directory.join(super).to_s end ``` For the App Template `super` returns `nil`, which...