1
0
mirror of https://github.com/lensapp/lens.git synced 2024-11-10 18:55:52 +03:00
lens/extensions/example-extension/renderer.tsx
Jari Kolehmainen df0f080380
Simplify pages/menus/registry extension api internal implementation (#1364)
Signed-off-by: Jari Kolehmainen <jari.kolehmainen@gmail.com>
Co-authored-by: Roman <ixrock@gmail.com>
2020-11-13 17:04:39 +02:00

27 lines
598 B
TypeScript

import { LensRendererExtension } from "@k8slens/extensions";
import { ExampleIcon, ExamplePage } from "./page"
import React from "react"
export default class ExampleExtension extends LensRendererExtension {
clusterPages = [
{
id: "example",
routePath: "/extension-example",
title: "Example Extension",
components: {
Page: () => <ExamplePage extension={this}/>,
}
}
]
clusterPageMenus = [
{
target: { pageId: "example", params: {} },
title: "Example Extension",
components: {
Icon: ExampleIcon,
}
}
]
}