Skip to content

The easy-to-use open source Business Intelligence and Embedded Analytics tool that lets everyone work with data :bar_chart:

358 B
Raw Blame
import path from "path";

import { GENERATED_COMPONENTS_DEFAULT_PATH } from "../constants/config";

export const getExampleComponentImportPath = (
  reactComponentDir = GENERATED_COMPONENTS_DEFAULT_PATH,
) => {
  const baseDir =
    reactComponentDir === "." ? "" : `/${path.basename(reactComponentDir)}`;

  return "<path-to-your-components>" + baseDir;
};