Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

web-analyst

thimpat118MIT3.5.6

Web Analyst is a simple back-end tracking system to measure your web app performance.

tracking, system, statistics, visits, number, of, visitors, web analyzer, web analytics, web analyst

readme

Web-Analyst

Web Analyst is a plugin for Genserve.

1. Installation

npm install web-analyst



2. Notes



3. Usage

Install Genserve
$> npm install genserve -g

Install Web-analyst
$> npm install web-analyst

Create a genserve config file and add a plugin section
{
  "plugins": [
    {
      "name": "web-analyst",
      "modulename": "web-analyst@latest",
      "pages": [
        ".*\\.html\\b",
        "\\/$"
      ],
      "earnings": [
        "\\?p=(.*)"
      ],
      "ignore": [
        "something.html"
      ],
      "users": {
        "admin": {
          "password": "admin"
        },
        "some-email@example.com": {
          "password": "secret"
        }
      }
    }
  ]
}

All values are optional apart from the name

  • name : Plugin name (required)
  • modulename : Plugin version to install
  • pages : Regex list for defining which pages need to be taken into account in the statistics
  • earning : Pattern to identify earnings
  • ignore : Pattern to identify pages to ignore
  • users : Users allowed to the statistic area. Default => user:admin password:admin
  • credentials: Path to a .cjs file containing allowed user list .i.e "/path/to/credentials.cjs" (The above field has precedence over this one)

Content Example for "credentials.cjs"
module.exports = {
  "admin": {
    "password": "admin"
  }
};


4. Preview

Screenshot