"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.default = void 0;

var _utils = require("../utils");

class WebpackWatchRunPlugin {
  apply(compiler) {
    compiler.hooks.watchRun.tap('WatchRun', comp => {
      const changedTimes = comp.watchFileSystem.watcher.mtimes;
      const changedFiles = Object.keys(changedTimes).map(file => `\n  ${file}`).join('');

      if (changedFiles.length) {
        (0, _utils.log)('====================================');
        (0, _utils.log)('NEW BUILD FILES CHANGED:', changedFiles);
        (0, _utils.log)('====================================');
      }
    });
  }

}

exports.default = WebpackWatchRunPlugin;