API for rete-readonly-plugin package - Rete.js

API for rete-readonly-plugin package

ReadonlyPlugin

index.ts

Readonly plugin, disables all user interactions

ts
class ReadonlyPlugin<Schemes extends BaseSchemes>
ParameterExtendsDescription
SchemesBaseSchemes

Listens nodecreate connectioncreate nodetranslate connectionpick

Examples

ts
const readonly = new ReadonlyPlugin<Schemes>();
editor.use(readonly.root);
editor.use(area);
area.use(readonly.area);
area.use(render);
connection.use(readonly.connection);
area.use(connection);

enabled

index.ts

Readonly mode state

ts
enabled: boolean;

disable

index.ts

Disable the readonly mode

ts
disable(): void

Returns void

enable

index.ts

Enable the readonly mode

ts
enable(): void

Returns void