2025-03-05 14:35:46 +01:00

9 lines
262 B
Python

from importlib.resources import files, as_file
from os import path
def get_resource_path(module: str, name: str) -> str:
with as_file(files(module)) as file:
p = path.join(file, name)
return p
# print(get_resource_path("resources", "about.md"))