granite icon indicating copy to clipboard operation
granite copied to clipboard

Make Granite::Base a module if possible

Open watzon opened this issue 5 years ago • 0 comments

I've got a special case going on right now, but I can think of multiple instances where a module will serve much better than a class. The main two I can think of are:

  1. You want granite to be an optional dependency, so in a class you want to override some class definitions and include Granite (my case)
  2. Your model class needs to extend another type. Having to extend granite will keep you from doing that.

This would obviously be a breaking change, but maybe it doesn't have to be. If the logic in Granite::Base were moved into a module with a different name, and then that module were included into Granite::Base we could probably have our cake and eat it too.

Thoughts?

watzon avatar Feb 21 '20 01:02 watzon