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

Commit

Permalink
watch recursive
Browse files Browse the repository at this point in the history
Summary: Plugin files in subfolders were not watched. Adding recursive flag to reload plugins, even when there are changes in any of the plugin's subdirectories.

Reviewed By: jknoxville

Differential Revision: D14100394

fbshipit-source-id: 2a0b5e35df4bbbfe6cf8a0fafd5271222d99a46c
  • Loading branch information
danielbuechele authored and facebook-github-bot committed Feb 15, 2019
1 parent d5dc3f9 commit c675211
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion static/compilePlugins.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ function watchChanges(
console.log('🕵️‍ Watching for plugin changes');

Object.values(plugins).map(plugin =>
fs.watch(plugin.rootDir, (eventType, filename) => {
fs.watch(plugin.rootDir, {recursive: true}, (eventType, filename) => {
// only recompile for changes in not hidden files. Watchman might create
// a file called .watchman-cookie
if (!filename.startsWith('.')) {
Expand Down

0 comments on commit c675211

Please sign in to comment.