blockly > Field > fromJson

Field.fromJson() method

Subclasses should reimplement this method to construct their Field subclass from a JSON arg object.

It is an error to attempt to register a field subclass in the FieldRegistry if that subclass has not overridden this method.

Signature:

static fromJson(_options: FieldConfig): Field;

Parameters

Parameter Type Description
_options FieldConfig JSON configuration object with properties needed to configure a specific field.

Returns:

Field