farm
farm copied to clipboard
refactor hmr config parse feature
What problem does this feature solve?
In the current project, the function of loading hmr configuration is too complicated. I hope that the relevant functions can be reconstructed into the following logic:
- use user config. when hmr_port is be used by other sw, throw error (in this case, farm cannot guarantee the availability of self-increasing ports. eg. reverse proxy)
- in default, hmr use 'auto' path and port (determined by browser,same as what browser use (not farm's default config))
more discussion is welcome, if there are no other comments I will submit a PR later.😊
What does the proposed API look like?
nothing changed
PR welcome, as long as there's not breaking changes