Tests for CableReady::Identifiable and CableReady::OperationBuilder#4
Tests for CableReady::Identifiable and CableReady::OperationBuilder#4leastbad merged 3 commits intoleastbad:memoryfrom
CableReady::Identifiable and CableReady::OperationBuilder#4Conversation
|
There's lots to love here, but let me explain my reasoning behind In today's CR, There's also the relatively undiscussed stimulusreflex#110 which I recognize isn't as sexy but it comes with a very interesting capability, which is the opportunity to stagger individual operations. This provides developers with a chance to implement chains of functionality that fire off in a sequence. Being able to send a time-staggered set of operations to the same element with very little code is exciting - it's the sort of thing I use to build interfaces that feel alive. (I know this doesn't directly contradict a The main issue I have with this you probably saw coming because it's the same issue I had with stimulusreflex#91, which is that it introduces something that looks like an operation but isn't. I'm actually really concerned that this will be the straw that breaks the camel's back when it comes to people wrapping their heads around the library. So, while I can be honest and say that I don't love the proposed change, the API syntax is a big enough deal that I would be trying to find another way to do this even if I did love it. Code feedback! Only after typing all of the above, I realize/think that you're proposing the Why do you need to require Why did you remove the Actually, I just had that 🤯 feeling because I think you didn't remove prefixes, you just saw a higher-level abstraction for all three cases that I didn't previously perceive. So: can you verify that you didn't change the functionality, just improved the implementation? If so, I can get used to that! I think that's everything. Thanks again, Marco! |
CableReady::OperationBuilder#selector + TestsCableReady::Identifiable? and CableReady::OperationBuilder`
CableReady::Identifiable? and CableReady::OperationBuilder`CableReady::Identifiable and CableReady::OperationBuilder
|
As discussed on Discord:
|
Here is a proposal to further improve the awesome PR stimulusreflex#107.
This PR adds:
a newCableReady::OperationBuilder#selectormethodThis method can be useful to explicit define which selector should be used. Previously theprevious_selectorwas just set implicitly if you called another operation before. With#selectoryou can explicitly control the selector.tests for the above mentionedCableReady::OperationBuilder#selectormore tests for
CableReady::OperationBuildera small refactoring for
CableReady::Identifiablea ton of tests for
CableReady::Identifiable