Resolved conflicts in Your First Extension after rebasing from master Reworked extensions/README.md Signed-off-by: Paul Williams <pawilliams@mirantis.com> Reworked the content in your-first-extension.md Signed-off-by: Paul Williams <pawilliams@mirantis.com> Reworked beginning of extension-anatomy.md Signed-off-by: Paul Williams <pawilliams@mirantis.com> Reworked the writing in extensions/get-started/anatomy.md Signed-off-by: Paul Williams <pawilliams@mirantis.com> Reworked beginning of wrapping-up.md Signed-off-by: Paul Williams <pawilliams@mirantis.com> Squashed 3 commits Reworked writing in wrapping-up.md Signed-off-by: Paul Williams <pawilliams@mirantis.com> Reworked content throughout Extension Development > Getting Started and squashed commits Removed extensions/capabilities/README.md and extensions/testing-and-publishing/bundling.md from mkdocs.yml nav Signed-off-by: Paul Williams <pawilliams@mirantis.com> Added extensions/get-started/overview.md to mkdocs.yml nav, reworked writing in extensions/get-started/wrapping-up.md and extensions/get-started/overview.md, changed links that pointed to extensions/capabilities/overview.md to go to extensions/capabilities/common-capabilities.md instead Signed-off-by: Paul Williams <pawilliams@mirantis.com> Changed all titles throughout docs, including in body, to title case Signed-off-by: Paul Williams <pawilliams@mirantis.com> Reworked bullets in extensions/get-started/anatomy.md Signed-off-by: Paul Williams <pawilliams@mirantis.com> Intergrated Windows instructions into your-first-extension.md, made minor edits throughout extensions/get-started and fixed a couple titles in mkdocs.yml nav Signed-off-by: Paul Williams <pawilliams@mirantis.com> Changed Extension Development > Get Started to Getting Started in mkdocs.yml Signed-off-by: Paul Williams <pawilliams@mirantis.com>
1.5 KiB
Extension Development Overview
This is a general overview to how the development of an extension will procede. For building extensions there will be a few things that you should have installed, and some other things that might be of help.
Required:
- Node.js
- Git
- Some sort of text editor – we recommend VSCode
- We use Webpack for compilation. All extension need to be at least compatable with a webpack system.
Recommended:
All Lens extensions are javascript packages. We recommend that you program in Typescript because it catches many common errors.
Lens is a standard Electron application with both main and renderer processes. An extension is made up of two parts, one for each of Lens's core processes. When an extension is loaded, each part is first loaded and issues a notification that it has been loaded. From there, the extension can start doing is work.
Lens uses React as its UI framework and provides some of Lens's own components for reuse with extensions. An extension is resonsible for the lifetime of any resources it spins up. If an extension's main part starts new processes they all must be stopped and cleaned up when the extension is deactivated or unloaded.
See Your First Extension to get started.