Utility library that allows transform requests to a format that facilitates create UI that manipulates requests
You can simply add the witnet-radon-js
package as a
dependency with npm:
yarn add witnet-radon-js
witnet-radon-js
exports four classes:
- Radon
- Source
- Script
- Operator
It has the following methods:
- getMir(): MirRequest
- getMarkup(): MarkupRequest
- updateSource(sourceIndex: number, { kind: string, url: string }): void
- deleteSource(index: number): void
- update(id: number, value: any): void
- addOperator(scriptId: number): void
- addSource(scriptId: number): void
It has the following methods:
- update(args: { kind: string, url: string }): void
- getMir(): MirSource
- getMarkup(): MarkupSource
- getOutputType(): OutputType
It has the following methods:
- getMir(): MirScript
- getMarkup(): MarkupScript
- validateScript (): MarkupSource
- onChildrenEvent(): { emit: Function }
- getOutputType(): OutputType
- getLastOperator(): Operator | null
- push(operator: MirOperator): void
- addOperator(): void
It has the following methods:
- update(value: OperatorName | OperatorCode): void
- getMir(): MirOperator
- getMarkup: MarkupOperator
It has the following methods:
- getMir(): MirArgument
- getMarkup(): MarkupOperator
- update(value: string | number | boolean | Filter): void
witnet-radon-js
is published under the GPL-3.0.