draper icon indicating copy to clipboard operation
draper copied to clipboard

Decorators/View-Models for Rails Applications

Results 70 draper issues
Sort by recently updated
recently updated
newest added

## Description This PR adds Ruby 3.1 and 3.2 to the CI matrix, and fix CI failure in Ruby 3. Here are the details: - **Address CI failure in Ruby...

## Description `Draper::Collection#respond_to?` does not work properly when using a non AR object, eg: ```ruby class FooDecorator < Draper::Decorator; end decorator_collection = FooDecorator.decorate_collection([Object.new]) decorator_collection.respond_to?(:limit) #=> true decorator_collection.limit(10) # Raises NoMethodError:...

Hi, I'm working on a project where Controllers and routes are namespaced but models are not. This is how my scaffold are generated: ``` bundle exec rails g model Client...

reproduced
namespaces

Hi👋 First of all thank you for the very helpful gem! I found an unexpected behavior while using draper and would like to report it. When the `frozen?` method is...

_(sorry in advance if I missed an issue or something in the docs)_ Let's say I have two model classes, `Book` and `Author`. `Book` implements an `author_name` method that delegates...

Hello guys, I upgraded my Ruby for 3.0 from 2.7 and I'm having some troubles. I have this helper in application_helper.rb: ```ruby def format_datetime(date, format: :small) I18n.l(date, format: format) rescue...

## Description This reduces unnecessary redirection from http://... to https://... when someone visits this gem's homepage via https://rubygems.org/gems/draper or some tools or APIs that use the gem's metadata.

## Description Warnings generated by Ruby 2.7 regarding kwargs were fixed with this patch: https://github.com/drapergem/draper/pull/885. However, I ran into a lingering one generated by the `Finders` module `method_missing` method. Adding...

## Description Currently, `delegatable?` call `private_methods` to check method is private or not. The `private_methods` generates an Array of methods per call. So a method call via `delegate_all` generates an...