mirror of
https://github.com/Tencent/Hippy.git
synced 2026-10-20 23:56:19 +08:00
26e6434b75
- hippy-vue: ElementNode add repaintWithChildren API - hippy-vue: support remove outdated style of HMR chunk - hippy-vue-loader: support style hmr - hippy-vue-css-loader: support remove outdated style of HMR chunk - debug-server, vue-demo, react-demo, hippy-react: support hmr - debug-server: add hippy-dev command
16 lines
313 B
JavaScript
16 lines
313 B
JavaScript
import url from 'url';
|
|
|
|
function createSocketURL(parsedURL) {
|
|
const { hostname, port, pathname } = parsedURL;
|
|
|
|
return url.format({
|
|
protocol: 'ws:',
|
|
hostname: hostname || 'localhost',
|
|
port: port || 38988,
|
|
pathname: pathname || '/ws',
|
|
slashes: true,
|
|
});
|
|
}
|
|
|
|
export default createSocketURL;
|