LiveReload Server (Node.js - Legacy)

0.2.3 · abandoned · verified Sun Apr 19

This entry describes the `livereload-server` package at version `0.2.3`, an extremely early and now effectively abandoned implementation of the LiveReload 3 web socket and HTTP server for Node.js. It targets Node.js versions `>= 0.6.0`, which are long past end-of-life and present significant security vulnerabilities and compatibility issues with modern JavaScript ecosystems. While its purpose was to provide real-time browser reloading during development upon file changes, this specific package version is not suitable for contemporary projects. Developers seeking LiveReload functionality in Node.js should instead use the more actively maintained `livereload` npm package (currently v0.10.x), which serves as its spiritual successor under the same LiveReload organization. This library is primarily of historical interest.

Common errors

Warnings

Install

Imports

Quickstart

Demonstrates how to start the legacy LiveReload server. This code is illustrative of its use but is not recommended for modern development due to severe age-related issues.

const livereload = require('livereload-server');

const server = livereload.createServer({
  port: 35729, // Default LiveReload port
  // No specific options were common for this extremely old version, 
  // and its internal implementation details are obscure.
  // Modern 'livereload' package options (like 'exts', 'delay', 'https') are not applicable here.
});

// In a real scenario, you'd integrate this with a simple HTTP server
// to serve static files and inject the LiveReload client script.
// For Node.js 0.6, this would likely involve Node's built-in http module.
// Example (highly simplified, assumes a server is already serving files):
// This package typically *only* provides the websocket part.

console.log('LiveReload server (legacy 0.2.3) started on port 35729.');
console.log('Ensure your browser extension or client-side script is configured to connect to this port.');
console.log('Note: This package is for historical context; use the `livereload` npm package for modern projects.');

view raw JSON →