UNPKG

@mintlify/previewing

Version:

Preview Mintlify docs locally

40 lines (39 loc) 1.56 kB
import os from 'os'; import path from 'path'; import * as url from 'url'; // Change this to bump to a newer version of mint's client export const TARGET_MINT_VERSION = 'v0.0.1055'; // package installation location export const INSTALL_PATH = url.fileURLToPath(new URL('.', import.meta.url)); export const HOME_DIR = os.homedir(); export const DOT_MINTLIFY = path.join(HOME_DIR, '.mintlify'); export const MINT_PATH = path.join(DOT_MINTLIFY, 'mint'); export const VERSION_PATH = path.join(MINT_PATH, 'mint-version.txt'); export const CLIENT_PATH = path.join(MINT_PATH, 'apps', 'client'); const NEXT_DIST_SERVER_PATH = path.join(MINT_PATH, 'node_modules', 'next', 'dist', 'server'); export const NEXT_SIDE_EFFECT_PATH = path.join(NEXT_DIST_SERVER_PATH, 'next.js'); export const NEXT_ROUTER_SERVER_PATH = path.join(NEXT_DIST_SERVER_PATH, 'lib', 'router-server.js'); export const NEXT_CONFIG_PATH = path.join(CLIENT_PATH, '.next', 'required-server-files.json'); export const NEXT_PUBLIC_PATH = path.join(CLIENT_PATH, 'public'); export const NEXT_PROPS_PATH = path.join(CLIENT_PATH, 'src', '_props'); export const TAR_URL = `https://mint-releases.b-cdn.net/mint-${TARGET_MINT_VERSION.slice(1)}.tar.gz`; export const TAR_PATH = path.join(DOT_MINTLIFY, `mint.tar.gz`); // command execution location export const CMD_EXEC_PATH = process.cwd(); export const SUPPORTED_MEDIA_EXTENSIONS = [ 'jpeg', 'jpg', 'jfif', 'pjpeg', 'pjp', 'png', 'svg', 'svgz', 'ico', 'webp', 'gif', 'apng', 'avif', 'bmp', 'mp4', ];