Fix image in meta and other details

This commit is contained in:
prototypa
2022-08-25 00:46:15 -04:00
parent b9b8feac44
commit 0a7b84b816
13 changed files with 67 additions and 49 deletions

View File

@@ -0,0 +1,12 @@
import path from "path";
import { fileURLToPath } from "url";
const __dirname = path.dirname(fileURLToPath(import.meta.url));
export const getProjectRootDir = () => {
const mode = import.meta.env.MODE;
return mode === "production"
? path.join(__dirname, "../")
: path.join(__dirname, "../../");
};