Skip to content
This repository has been archived by the owner on Oct 29, 2024. It is now read-only.

zanaca/koa-robotstxt

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

koa-robotstxt Build Status

Koa middleware for serving the robots.txt file..

Installation

$ npm install koa-robotstxt

Example

var koa = require('koa');
var robotstxt = require('koa-robotstxt');
var app = koa();

app.use(robotstxt(__dirname + '/public/robots.txt'));

API

robotstxt(path, [options])

Returns a middleware serving the robots.txt found on the given path.

options

  • maxAge cache-control max-age directive in ms, defaulting to 1 day.

License

MIT

About

Serving robots.txt in koa

Resources

Stars

Watchers

Forks

Packages

No packages published