open-scd icon indicating copy to clipboard operation
open-scd copied to clipboard

Tutorial on write an OpenSCD-core plugin

Open Sander3003 opened this issue 2 years ago • 4 comments

**Is your feature request related to a problem? Please describe. ** As a developer, I would like to read a tutorial how to build a plug-in So I can develop my own basic plug-in that fits my needs.

Describe the solution you'd like Documentation with the steps to build a plug-in. It can be in written form or a video.

Requirements Overview of steps Things to watch or keep in mind Detailed description per step

Open Questions: Where to put the documentation? .github

Do we need to provide an example/skelleton? Refer to an example container

How to make a hello world plug-in with basic document handling? Re-use examples from frameworks is fine.

Background: A framework like Lit can be used as example Typescript can be used as example

Sander3003 avatar Nov 01 '22 15:11 Sander3003

@pascalwilbrink can you improve this issue?

Sander3003 avatar Nov 01 '22 15:11 Sander3003

FWIW, this branch was intended to be part of a tutorial, but given the work on open-scd-core I stopped looking into it further https://github.com/danyill/open-scd/tree/Example-Menu-Plugin

It is a simple menu plugin which shows a dialog and does something with MAC addresses which I thought was relatable. I was thinking of doing an example of each type of plugin (I would like a validator plugin example at some stage).

danyill avatar Nov 04 '22 09:11 danyill

We will have three template plugins in the near future. One to develop UI components like textfield, another one to start developing a plugin and yet another one for distributors. If you want to have an example on how a very basic plugin looks like, see oscd-open

JakobVogelsang avatar Nov 04 '22 10:11 JakobVogelsang

Added it here: https://github.com/openscd/Documentation/pull/4

Sander3003 avatar Feb 05 '24 10:02 Sander3003