Skip to main content

fromString

scrypt-ts-opcat v1.0.1


scrypt-ts-opcat / Opcode / fromString

Function: fromString()

fromString(str): Opcode

Defined in: node_modules/@opcat-labs/opcat/types/opcode.d.cts:75

Creates an Opcode instance from a string representation.

Parameters

str

string

The string representation of the opcode.

Returns

Opcode

A new Opcode instance corresponding to the input string.

Throws

If the input string is not a valid opcode representation.