Jens Ljungblad

Results 42 comments of Jens Ljungblad

I experimented a bit with this and tried the following: ```ruby module Godmin module Controllers def self.resources_controller(parent) resources_controller = Class.new(parent) do def index; end end Godmin.const_set("ResourcesController", resources_controller) end end end...

Another alternative would be to skip the `resources_controller` entirely and move all of that functionality to the `application_controller`. That would cater more towards the 80% use case and not be...

@topherfangio I never tried that! Did you get it working?

> I still really love the simplicity of the DSL you've created, but if ViewComponent is more mainstream and offers roughly the same features, I'll probably go with that. Thanks!...

Sounds like a good idea!

Hey there! Yeah I'm open to PRs, or discussions around changes. There's also the new https://github.com/github/actionview-component which you might be interested in, as it is headed for Rails master, I...

@topherfangio I just looked at it briefly yesterday for the first time :) Couldn't figure out how to access the instantiated component from the template though, which would be kind...

Sounds promising! I have very limited time, but perhaps it's a good idea for you to test it out in your project first? Pretty cool that you were able to...

@sabman Could you do something similar to the elasticsearch gem? ```ruby Elasticsearch::Client.new( host: ENV.fetch("ELASTICSEARCH_HOST", nil), user: ENV.fetch("ELASTICSEARCH_USER", nil), password: ENV.fetch("ELASTICSEARCH_PASSWORD", nil), request_timeout: 10 ) do |faraday| faraday.request(:instrumentation, name: "request.elasticsearch") end...