@lynx-dev/webpack-dev-transport-canary
v0.0.1
Published
A webpack dev-server transport implementation for Lynx
Downloads
90
Readme
A webpack devServer transport implementation for Lynx.
Client
The client transport can be used in the
devServer.client.webSocketTransport
configuration of webpack.config.js
.
// webpack.config.js
import { createRequire } from 'node:module';
import { LynxTransportServer } from '@lynx-dev/webpack-dev-transport';
const require = createRequire(import.meta.url);
export default {
devServer: {
client: {
webSocketTransport: require.resolve(
'@lynx-dev/webpack-dev-transport/client',
),
},
},
};
Server
The server transport can be used in the
devServer.webSocketServer
configuration of webpack.config.js
.
// webpack.config.js
import { LynxTransportServer } from '@lynx-dev/webpack-dev-transport';
export default {
devServer: {
allowedHosts: 'all', // disable host checks, which Lynx does not support
webSocketServer: LynxTransportServer,
},
};