npm Community Forum (Archive)

The npm community forum has been discontinued.

To discuss usage of npm, visit the GitHub Support Community.

npm run serve handle post request on static page

Hi all,
In Nginx we could do the following to allow for post request to access static page.

To allow POST on static pages

    error_page  405     =200 $uri;

I wonder if there is the equivalent configuration for
npm run serve

I need it to serve static page to mimic my pages responses when testing.

Best Regards,

So I managed to bypass the problem with a simple reroute to my nginx post to static enabled site with a proxy configuration instead through vue.config.js

module.exports = {
devServer: {
proxy: ‘http://localhost