This example shows how to use Framing components to divide a web server application into distinct sections or concerns.
npm installnpm start
The postinstall will automatically execute the build gulp task in the client component.
These are the components that comprise the web server. The application has been divided into the server, client, real time comm, and chat components.
The server component sets up the necessary infrastructure for a bare-bones web server using the express web framework. It enables a basic file-system based session store for cookies. Anything that wishes to route through the web server would import from this component.
The client component comprises the routes and views for the client browser. It uses nunjucks and webpack to build the UI in the browser. Gulp is used to build the JavaScript bundle.
The real-time-comm component enables socket.io for the server. It imports from the server component and then enables the socket io listeners.
The chat component imports from the real-time-comm component and establishes the chat namespace in socket.io and performs some basic messaging with the client browsers.
npm run debugnpm run dev-ui