Skip to content

Instantly share code, notes, and snippets.

View jacksierkstra's full-sized avatar

Jack Sierkstra jacksierkstra

View GitHub Profile
@dunnza
dunnza / setupProxy.js
Last active November 7, 2022 07:54
How to proxy api requests with NTLM authentication in a create-react-app project
const http = require("http");
const proxy = require("http-proxy-middleware");
module.exports = function(app) {
app.use(
"/api",
proxy({
agent: new http.Agent({ keepAlive: true }),
target: "http://example.com/",
onProxyRes(proxyRes) {