Created by: iamandrewluca
Allow PUBLIC_URL in development mode
-
Feature ( react-dev-utils/getPublicUrlOrPath) -
Tests -
Docs -
Types DefinitelyTyped/DefinitelyTyped/pull/40982
Public API
-
In development mode browser is opened at desired pathname -
Redirect to desired pathname if does not start with it ( react-dev-utils/redirectServedPathMiddleware) -
Assets will be served at desired pathname (webpack/webpack-dev-server/pull/2150) -
If desired pathname is a relative path, app will be served at /
Private API
-
Combined paths.publicUrlandpaths.servedPathintopaths.publicUrlOrPath -
Extracted all logic into react-dev-utils/getPublicUrlOrPath(no side effects) -
Moved evalSourceMapMiddlewareanderrorOverlayMiddlewarefirst in the middleware chain, redirect does not affect them. -
Moved proxy middleware after redirect (this is the case what most want, proxy should respect PUBLIC_URL -
Adapted noopServiceWorkerMiddlewareto serve fromservedPath -
Updated webpack-dev-server@3.9.0towebpack-dev-server@3.10.0
Blocked by webpack/webpack-dev-server/pull/2150
Blocked by webpack/webpack-dev-server/pull/2374
Blocked by https://github.com/webpack/webpack-dev-server new patch release
Closes #6280
Closes #6135 (closed)
Closes #4158