cellplatform / platform-0.2.0

/sys (shared system modules)
Other
4 stars 2 forks source link

Lens<T> using JSONPath arrays within events #179

Closed philcockfield closed 5 months ago

philcockfield commented 5 months ago

Changes:

TODO


Json.Path

Json.Path.resolve( 💦 )

type R = typeof root;
const root = {
  msg: 'hello',
  child: { foo: { count: 123 }, bar: null },
  list: [1, { msg: 'two' }, ['a', 'b', null]],
};

const res = Path.resolve<R>(root, ['child', 'foo', 'count']);

↑ module: sys.data.json