CVGenerator/modules/utils.py

10 lines
245 B
Python
Raw Normal View History

2023-04-26 17:07:49 +03:00
from json import loads
from pathlib import Path
from typing import Any, Union
def json_read(filepath: Union[str, Path]) -> Any:
with open(str(filepath), "r", encoding="utf-8") as file:
output = loads(file.read())
return output