🔧 Config init

This commit is contained in:
ful1e5 2020-08-15 09:36:23 +05:30
parent 9b5abcb4cb
commit f83aab5f8e

View file

@ -0,0 +1,17 @@
import path from "path";
import fs from "fs";
import { staticCursors, animatedCursors, animatedClip } from "./cursors.json";
// Source Directory
const svgsDir = path.resolve(__dirname, "svg");
// Resolve Paths for svg
const staticSvgs = staticCursors.map((svg: string) =>
path.resolve(svgsDir, svg)
);
// Out Directory
const bitmapsDir = path.resolve(process.cwd(), "bitmaps");
if (!fs.existsSync(bitmapsDir)) fs.mkdirSync(bitmapsDir);
export { staticSvgs, animatedCursors, svgsDir, bitmapsDir, animatedClip };