Registry / web-framework / pixl-server-web

pixl-server-web

JSON →
library3.0.4jsnpmunverified

A web server component for the pixl-server framework, supporting HTTP and HTTPS, static file serving, custom URI handlers, access control, request logging, and performance monitoring. Current stable version is 3.0.4. Release cadence is moderate; breaking changes are rare but documented. Key differentiators: deep integration with pixl-server ecosystem, extensive configuration options, and built-in support for features like compression, keep-alive, and request queuing.

npm install pixl-server-web
INSTALL
IMPORT
SIG · PIXL-SERVER-WEB
P
pixl-server-web
web-frameworkjavascriptv3.0.4
Install
—
Import
—
Disk
—
Pass rate
0/ 6
Env Coverage0 / 6
glibc
18–22
musl
18–22
Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
musl
node 18–226 runs
build_error
glibc
node 18–226 runs
build_error
Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

pixl-server-web
✓ require('pixl-server-web')
✗ import pixlServerWeb from 'pixl-server-web'
This package is CommonJS-only; ESM import is not supported.
PixlServerWeb
✓ const webServer = new(require('pixl-server-web').PixlServerWeb)()
✗ const webServer = new(require('pixl-server-web'))()
The default export is the package's root module; the constructor is on .PixlServerWeb.
HttpServer
✓ const HttpServer = require('pixl-server-web').HttpServer
✗ const HttpServer = require('pixl-server-web/http')
Sub-components are accessed via the main module, not separate files.

Initializes a pixl-server with the web component, serving static files from /var/www/html on port 8080.

const pixlServer = require('pixl-server'); const server = new pixlServer(); server.start({ __main: require('pixl-server-web'), web: { port: 8080, htdocs_dir: '/var/www/html', log_requests: true } }); console.log('Server running on http://localhost:8080');
Debug
Known issues
breakingv3.0.0 removed legacy_callback_support by default; must set config.legacy_callback_support=true if needed.
fix
Add 'legacy_callback_support: true' to web config.
affects: >=3.0.0
breakingv3.0.0 changed default for log_requests from false to true.
fix
Set 'log_requests: false' to suppress logs.
affects: >=3.0.0
deprecatedconfig.recent_requests is deprecated; use 'recent_requests_max' instead.
fix
Rename config key to 'recent_requests_max'.
affects: >=2.5.0
gotchaWhen using HTTPS, ensure the cert files are readable by the process user.
fix
Set proper file permissions or run process with elevated privileges.
affects: *
gotchaThe package does not support ESM imports; CommonJS only.
fix
Use require() instead of import.
affects: *
gotchaStatic file paths are relative to htdocs_dir; do not serve parent directories.
fix
Ensure all static files are within htdocs_dir.
affects: *
Errors
Common errors & fixes
Error: Cannot find module 'pixl-server-web'
Package not installed or peer dependency pixl-server is missing.
fix
Run 'npm install pixl-server pixl-server-web'.
TypeError: pixlServer.start is not a function
Incorrect initialization: missing __main configuration.
fix
Pass { __main: require('pixl-server-web'), web: {...} } to server.start().
Error: listen EADDRINUSE :::8080
Port 8080 is already in use.
fix
Change the port in config or kill the process using that port.
SyntaxError: Unable to parse JSON from request body
Invalid JSON in POST body.
fix
Send valid JSON with Content-Type: application/json.
Error: SSL certificate not found
HTTPS enabled but cert file path is incorrect or unreadable.
fix
Verify https_cert_file and https_key_file paths and permissions.
Upgrade
Version history
3.0.4latest on npm
Audit
Dependencies
pixl-serverrequiredCore framework for which this component is designed
pixl-classoptionalUsed for class-based inheritance and configuration
pixl-perfoptionalPerformance measurement library used by the request timing features
Agent activity
6 hits · last 30 days
node
6
Resources
pixl-server-web — npm install pixl-server-web · libregistry