Skip to content

Instantly share code, notes, and snippets.

@alanhoff
Created October 31, 2016 19:43
Show Gist options
  • Save alanhoff/79aac2f6b5b35cebc46c1da99b9731f2 to your computer and use it in GitHub Desktop.
Save alanhoff/79aac2f6b5b35cebc46c1da99b9731f2 to your computer and use it in GitHub Desktop.
const path = require('path')
const glob = require('glob')
glob.sync('minha_pasta/**/arquivo.js').forEach(caminho => require(path.normalize(__dirname, caminho)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment