Skip to content
This repository was archived by the owner on Nov 6, 2023. It is now read-only.

Commit 0cb1498

Browse files
authored
Merge pull request #66 from moeddami/master
Fix slow response time of requests
2 parents 5ed9899 + e7a8747 commit 0cb1498

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/VueCliMiddleware/VueDevelopmentServerMiddleware.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,11 @@ public static void Attach(
3636
var logger = LoggerFinder.GetOrCreateLogger(appBuilder, LogCategoryName);
3737
var portTask = StartVueCliServerAsync(sourcePath, scriptName, logger, port, runner, regex, forceKill);
3838

39-
// Everything we proxy is hardcoded to target http://localhost because:
39+
// Everything we proxy is hardcoded to target localhost because:
4040
// - the requests are always from the local machine (we're not accepting remote
4141
// requests that go directly to the vue-cli server)
4242
var targetUriTask = portTask.ContinueWith(
43-
task => new UriBuilder(https ? "https" : "http", "localhost", task.Result).Uri);
43+
task => new UriBuilder(https ? "https" : "http", "127.0.0.1", task.Result).Uri);
4444

4545
SpaProxyingExtensions.UseProxyToSpaDevelopmentServer(spaBuilder, () =>
4646
{

0 commit comments

Comments
 (0)