Rollup plugin for proxy SharePoint request in vite. Inspired by sp-rest-proxy.
import { defineConfig } from "vite";
import RollupPluginSPRestProxy from "rollup-plugin-sp-rest-proxy";
let rollupPluginSPRestProxy = new RollupPluginSPRestProxy();
export default defineConfig({
server: {
proxy: {
...rollupPluginSPRestProxy.viteProxySetting(),
},
},
plugins: [rollupPluginSPRestProxy.rollupPlugin()],
});
import { defineConfig } from "vite";
import RollupPluginSPRestProxy from "rollup-plugin-sp-rest-proxy";
let rollupPluginSPRestProxy = new RollupPluginSPRestProxy();
export default defineConfig(
RollupPluginSPRestProxy.mergeViteConfig({
/* self vite config */
})
);