Browse files

document opts.word

  • Loading branch information...
1 parent 584d2c4 commit b8d654a10cb2507d2a468b449e5fba1b46cdf9f0 @substack committed Nov 26, 2011
Showing with 9 additions and 4 deletions.
  1. +9 −4 README.markdown
13 README.markdown
@@ -39,20 +39,25 @@ methods
var detective = require('detective');
+detective(src, opts)
Give some source body `src`, return an array of all the require()s with string
+The options parameter `opts` is passed along to `detective.find()`.
+detective.find(src, opts)
Give some source body `src`, return an object with "strings" and "expressions"
arrays for each of the require() calls.
The "expressions" array will contain the stringified expressions.
+Optionally you can specify a different function besides `"require"` to analyze
+with `opts.word`.

0 comments on commit b8d654a

Please sign in to comment.