mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
update docs
Signed-off-by: Roman <ixrock@gmail.com>
This commit is contained in:
parent
e671d07eb2
commit
824d1022aa
@ -100,13 +100,22 @@ import { ExamplePage } from "./src/example-page"
|
|||||||
export default class ExampleRendererExtension extends LensRendererExtension {
|
export default class ExampleRendererExtension extends LensRendererExtension {
|
||||||
globalPages = [
|
globalPages = [
|
||||||
{
|
{
|
||||||
path: "/example-route",
|
routePath: "/items/:id?",
|
||||||
hideInMenu: true,
|
|
||||||
components: {
|
components: {
|
||||||
Page: ExamplePage,
|
Page: ExamplePage,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
||||||
|
globalPageMenus = [
|
||||||
|
{
|
||||||
|
url: "/items/1",
|
||||||
|
title: "Example page", // used in icon's tooltip
|
||||||
|
components: {
|
||||||
|
Icon: () => <Component.Icon material="arrow"/>,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
}
|
}
|
||||||
```
|
```
|
||||||
|
|
||||||
@ -146,11 +155,20 @@ import { ExampleIcon, ExamplePage } from "./src/page"
|
|||||||
export default class ExampleExtension extends LensRendererExtension {
|
export default class ExampleExtension extends LensRendererExtension {
|
||||||
clusterPages = [
|
clusterPages = [
|
||||||
{
|
{
|
||||||
path: "/extension-example",
|
routePath: "/extension-example",
|
||||||
title: "Example Extension",
|
exact: true,
|
||||||
components: {
|
components: {
|
||||||
Page: () => <ExamplePage extension={this}/>,
|
Page: () => <ExamplePage extension={this}/>,
|
||||||
MenuIcon: ExampleIcon,
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
|
||||||
|
clusterPageMenus = [
|
||||||
|
{
|
||||||
|
url: "/extension-example",
|
||||||
|
title: "Example Extension",
|
||||||
|
components: {
|
||||||
|
Icon: ExampleIcon,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
@ -84,11 +84,9 @@ import React from "react"
|
|||||||
export default class ExampleExtension extends LensRendererExtension {
|
export default class ExampleExtension extends LensRendererExtension {
|
||||||
clusterPages = [
|
clusterPages = [
|
||||||
{
|
{
|
||||||
path: "/extension-example",
|
routePath: "/extension-example",
|
||||||
title: "Hello World",
|
|
||||||
components: {
|
components: {
|
||||||
Page: () => <ExamplePage extension={this}/>,
|
Page: () => <ExamplePage extension={this}/>,
|
||||||
MenuIcon: ExampleIcon,
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user