import alchemyVite from "../vite/plugin.js";
const alchemy = (config = {}) => {
    // plugin is not required for react-router typegen, so return a no-op to avoid errors
    if (process.argv.some((arg) => arg.includes("react-router")) &&
        process.argv.includes("typegen")) {
        return null;
    }
    return alchemyVite({
        viteEnvironment: {
            name: "ssr",
        },
        ...config,
    });
};
export default alchemy;
//# sourceMappingURL=plugin.js.map