ghost-detect

1.0.14 • Public • Published

ghost-detect Build Status

Detect whether a site has been generated by the Ghost publishing platform.

Install

~ ❯❯❯ npm install --save ghost-detect

Usage

const ghostDetect = require('ghost-detect');
 
ghostDetect('nikolaskama.me').then(ghost => {
    console.log(ghost);
    //=> true
});
 
ghostDetect('google.com').then(ghost => {
    console.log(ghost);
    //=> false
});

API

ghostDetect(targets, [options])

Returns a Promise for a boolean which is true if any of the targets have been generated using the Ghost publishing platform.

targets

Type: string Array

One or more targets to check. Can either be a full URL like https://hostname or just hostname. When the protocol is missing from a target http is assumed.

options

timeout

Type: number

Timeout in milliseconds after which a request is considered failed. Default: 5000.

Related

  • ghost-detect.now - A minimal service to check whether a site has been generator by the Ghost publishing platform.

License

MIT © Nikolaos Kamarinakis

Readme

Keywords

Package Sidebar

Install

npm i ghost-detect

Weekly Downloads

0

Version

1.0.14

License

MIT

Unpacked Size

4.18 kB

Total Files

4

Last publish

Collaborators

  • k4m4