cloudfour / drizzle-builder

The tool for building a Drizzle.
MIT License
6 stars 3 forks source link

Pattern ordering #105

Closed calebeby closed 6 years ago

calebeby commented 6 years ago

Closes https://github.com/cloudfour/drizzle/issues/66

This addresses the ordering issue that @tylersticka had, by adding the ability to send patterns to the end of a collection. Negative values go to the beginning of the collection, items without values come next, and items with positive values go to the end.

I updated the pattern ordering fixture with a negative order property.

Also, this is a breaking change. This means we will need a new major release (but we are currently 0.0.10 🤔. Does this mean we should release 1.0.0?)

Also I haven't addressed this:

Because we now have helpers that can sort by any property, we might want to focus on creating a common sorting function that possesses the logic to infer default values (e.g. 0) and that isn't limited to just properties named "order".

tylersticka commented 6 years ago

Also, this is a breaking change. This means we will need a new major release (but we are currently 0.0.10 🤔. Does this mean we should release 1.0.0?)

Maybe! What do you think, @gerardo-rodriguez?

gerardo-rodriguez commented 6 years ago

Does this mean we should release 1.0.0?

Maybe! What do you think, @gerardo-rodriguez?

@tylersticka @calebeby Yep, if it's a breaking change it should be 1.0.0. 😉