I wrote:
> I've conceptualized a generic hierarchical object-builder, for use
> with Flow. View my proposal 
> athttps://github.com/bemson/Flow/issues/7#issuecomment-1100957

On second thought, I won't be changing the parameter format at all. I
suddenly remembered how key order only impacts one feature of Flow:
the "_over" component. The _over component is triggered when Flow
bypasses a state. All other components are based on hierarchy (i.e.,
_in, _out, and _main).

Here is an example Flow using the _over component, and thus relies on
key order.

  var app = new Flow({
    one: {
      _over: function () {
        this.go('@self');
      },
      _main: doSomethingFirst
    },
    two: doSomethingSecond
  });
  app.two();

Here is the same functionality, from a Flow with a different program.

  var app = new Flow({
    _in: function () {
      this.go('one');
    },
    one: doSomethingFirst,
    two: doSomethingSecond
  });
  app.two();

Both Flows will invoke `doSomethingFirst()` before
`doSomethingSecond()`. The benefit of the _over component, is
isolating logic to a given state, instead of it's parent.

I will add cautionary notes in my documentation for the _over
component, but I'm not going to burn the forest for this tree. Those
interested in Flow, but wary of future browser issues, will be advised
to write their programs accordingly - without the _over component.
Regarding issue #7, I will update Flow to decline naming states with
integers, then close the issue.

- bemson

-- 
To view archived discussions from the original JSMentors Mailman list: 
http://www.mail-archive.com/[email protected]/

To search via a non-Google archive, visit here: 
http://www.mail-archive.com/[email protected]/

To unsubscribe from this group, send email to
[email protected]

Reply via email to