2010/4/13 Jeremy Evans <[email protected]>:
> Does anyone have any
> other ideas for features that they would like added to Sequel?
>
> Jeremy
I think documentation, as mentionned, can really get better.
Here are what I think :
* Do not compare Sequel to another ORM unless it's a page specific to
a comparison or a migration from. I never used AR, and it is confusing
to see it in advanced associations doc, for example.
* clean out README, there's too much in it.
* Have separate pages for models. Basic and advanced would be nice.
* There's a lot of doc in the patch notes, it would be nice if some of
them could be integrated. For example, the :clone thing that was
discussed a few days ago.
* Write a contribute page. I would love to help, but I don't know how.
I understand I can fork GH and then send pull requests, but I'm not
sufficiently skilled to understand everything you expect as base
contribution : code style, tests, ...
Granted, I don't have much time anyway.
* eager load could easily get a page on his own, it's a not a trivial
understanding imo.
As for improvements :
* case syntax, as I mentionned on your blog, is very confusing. I
don't know how it could really be improved though. Maybe replacing it
with else would make it slightly less surprising.
Ideally (for me) :
CASE WHEN
now : {{:a=>[2,3]}=>1}.case(0)
maybe : [ {:a => [2,3]}.then(1), {:b => 4}.then(2)].else(0)
CASE c WHEN
now : {:a=>1, {:b=>2}].case(:d, :c) (typo from the doc)
maybe : :c.when([:a.then(1), :b.then(2)]).else(:d)
dunno if it would fit in sequel though.
* ancestors and descendants (non-rcte) as a keyword would be really nice.
class Node < Sequel::Model
many_to_one :parent, :class=>self
one_to_many :children, :key=>:parent_id, :class=>self
ancestors :parent
descendants :children
end
Node.filter(:id => 34).ancestors.all
Node.filter(:id => 34).descendants.all
Node.filter(:id => 34).descendants(3).all (depth of descendants)
That's all I can think right now, but I'm sure there are a lot of other things.
regards
Simon
--
You received this message because you are subscribed to the Google Groups
"sequel-talk" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sequel-talk?hl=en.