Closed libitx closed 4 years ago
The latest commit includes some scaffold code for the Operate class: https://github.com/libitx/op_agent-js/blob/master/lib/index.js
Operate
This issue broadly includes:
Operate.loadTape()
Operate.loadTapesBy()
The way I envisage global config being edited is something like this:
// Any passed options are merged into the global config Operate.config.set({ aliases: { 'abcdef': 'ffeedd' } })
For loadTape() and loadTapesBy() refer to the elixir implementation for reference: https://github.com/operate-bsv/op_agent/blob/master/lib/operate.ex
loadTape()
loadTapesBy()
Both functions can be passed an options object which will override the global config. Both functions will return a Promise which will resolve to a Tape instance (or array or Tapes).
The above work should allow you to implement two pending tests which you can refer to in Elixir: https://github.com/operate-bsv/op_agent/blob/master/test/operate_test.exs
If you can think of any more tests that make sense to add then please do.
The latest commit includes some scaffold code for the
Operate
class: https://github.com/libitx/op_agent-js/blob/master/lib/index.jsThis issue broadly includes:
Operate.loadTape()
static methodOperate.loadTapesBy()
static methodConfig
The way I envisage global config being edited is something like this:
Loading tapes
For
loadTape()
andloadTapesBy()
refer to the elixir implementation for reference: https://github.com/operate-bsv/op_agent/blob/master/lib/operate.exBoth functions can be passed an options object which will override the global config. Both functions will return a Promise which will resolve to a Tape instance (or array or Tapes).
Testing
The above work should allow you to implement two pending tests which you can refer to in Elixir: https://github.com/operate-bsv/op_agent/blob/master/test/operate_test.exs
If you can think of any more tests that make sense to add then please do.