Its alive!
This commit is contained in:
parent
2aa9026392
commit
bbb955df1b
4 changed files with 15 additions and 6 deletions
|
|
@ -1,4 +1,5 @@
|
||||||
from fastapi import APIRouter
|
from fastapi import APIRouter
|
||||||
|
from fastapi.staticfiles import StaticFiles
|
||||||
|
|
||||||
from lnbits.db import Database
|
from lnbits.db import Database
|
||||||
from lnbits.helpers import template_renderer
|
from lnbits.helpers import template_renderer
|
||||||
|
|
@ -7,6 +8,14 @@ db = Database("ext_example")
|
||||||
|
|
||||||
example_ext: APIRouter = APIRouter(prefix="/example", tags=["example"])
|
example_ext: APIRouter = APIRouter(prefix="/example", tags=["example"])
|
||||||
|
|
||||||
|
example_static_files = [
|
||||||
|
{
|
||||||
|
"path": "/example/static",
|
||||||
|
"app": StaticFiles(packages=[("lnbits", "extensions/example/static")]),
|
||||||
|
"name": "example_static",
|
||||||
|
}
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
def example_renderer():
|
def example_renderer():
|
||||||
return template_renderer(["lnbits/extensions/example/templates"])
|
return template_renderer(["lnbits/extensions/example/templates"])
|
||||||
|
|
|
||||||
6
lnbits/extensions/example/config.json
Normal file
6
lnbits/extensions/example/config.json
Normal file
|
|
@ -0,0 +1,6 @@
|
||||||
|
{
|
||||||
|
"name": "Build your own!",
|
||||||
|
"short_description": "Extension building guide",
|
||||||
|
"tile": "/example/static/bitcoin-extension.png",
|
||||||
|
"contributors": ["github_username"]
|
||||||
|
}
|
||||||
|
|
@ -1,6 +0,0 @@
|
||||||
{
|
|
||||||
"name": "Build your own!!",
|
|
||||||
"short_description": "Join us, make an extension",
|
|
||||||
"tile": "/cashu/static/image/tile.png",
|
|
||||||
"contributors": ["github_username"]
|
|
||||||
}
|
|
||||||
BIN
lnbits/extensions/example/static/bitcoin-extension.png
Normal file
BIN
lnbits/extensions/example/static/bitcoin-extension.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 5.2 KiB |
Loading…
Add table
Add a link
Reference in a new issue