Skip to content

Can someone provide an example of overriding the proxy URL with craco ? #525

Closed Answered by olignyf
olignyf asked this question in Q&A
Discussion options

You must be logged in to vote

Oh I figured it out... proxy is an array

module.exports = {
  devServer: (devServerConfig, { env, paths, proxy, allowedHost }) => {     
    proxy[0].target = "https://my-url.com";
    devServerConfig.proxy = proxy;
    return devServerConfig;
   },
(...)

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by olignyf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant