mirror of
https://git.datalinker.icu/kijai/ComfyUI-KJNodes.git
synced 2025-12-08 20:34:35 +08:00
Added some js code (thanks melMass) to allow help popups on the nodes, and initial documentation on some nodes.
16 lines
545 B
Python
16 lines
545 B
Python
from .nodes import NODE_CLASS_MAPPINGS, NODE_DISPLAY_NAME_MAPPINGS
|
|
__all__ = ["NODE_CLASS_MAPPINGS", "NODE_DISPLAY_NAME_MAPPINGS", "WEB_DIRECTORY"]
|
|
|
|
WEB_DIRECTORY = "./web"
|
|
|
|
from aiohttp import web
|
|
from server import PromptServer
|
|
from pathlib import Path
|
|
|
|
if hasattr(PromptServer, "instance"):
|
|
|
|
# NOTE: we add an extra static path to avoid comfy mechanism
|
|
# that loads every script in web.
|
|
PromptServer.instance.app.add_routes(
|
|
[web.static("/kjweb_async", (Path(__file__).parent.absolute() / "kjweb_async").as_posix())]
|
|
) |