@maxtropy/vite-plugin-isv-local
v0.1.0
Published
Shared Vite local development server configuration for Maxtropy ISV micro apps.
Readme
@maxtropy/vite-plugin-isv-local
Shared Vite local-development server configuration for Maxtropy ISV micro apps.
import { defineConfig } from "vite";
import { createIsvLocalDevServer } from "@maxtropy/vite-plugin-isv-local";
const isvLocalDev = createIsvLocalDevServer({
appName: "ms-example",
port: 8100,
target: "https://portal.test.maxtropy.com/infra/ms-example/",
proxyPrefixes: ["api", "server"],
extraProxies: {
"/legacy": { target: "https://legacy.test.maxtropy.com" }
}
});
export default defineConfig({
plugins: [isvLocalDev.plugin],
server: {
...isvLocalDev.server
}
});The plugin configures credentials CORS and handles OPTIONS only for the generated or explicitly registered proxy paths. Application HTTP clients must still opt into credentials, for example Axios withCredentials: true.
