Znack / robotstxt-webpack-plugin

A webpack plugin to output a robots.txt file

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

robotstxt-webpack-plugin

NPM version Travis Build Status dependencies Status devDependencies Status Greenkeeper badge

Webpack plugin for generate-robotstxt package. Generating robots.txt using webpack. Why your need robots.txt?

Install

npm install --save-dev robotstxt-webpack-plugin

Usage

const RobotstxtPlugin = require('robotstxt-webpack-plugin').default;

const options = {}; // see options below

module.exports = {
  plugins: [
    new RobotstxtPlugin(options)
  ]
}

Or

import RobotstxtPlugin from 'robotstxt-webpack-plugin';

const options = {}; // see options below

export default {
  plugins: [
    new RobotstxtPlugin(options)
  ]
};

Options

  • General options - see generate-robotstxt options.
  • dest - (optional) directory which will be saved robots.txt (relatively of the option output.path value).

Related

Contribution

Feel free to push your code if you agree with publishing under the MIT license.

About

A webpack plugin to output a robots.txt file

License:MIT License


Languages

Language:JavaScript 100.0%