1.0.1 • Published 8 years ago

greglearns-helper v1.0.1

Weekly downloads
3
License
ISC
Repository
github
Last release
8 years ago

node-greglearns-helper

Little helper functions that I use all the time.

This is probably something you don't want to use -- you should write your own that does the things you want it to do the way that you like them to be.

For each project, I like to have a 'helper.js' file at the project root. In that file, I require this one, and I also add this:

function requireFromRoot(file) {
  return require(__dirname + '/' + file)
}

That way, requiring project files becomes:

var help = require('../../<whereever the project root is/helper')
var otherProjectFile = help.requireFromRoot('lib/whatever')
1.0.1

8 years ago

1.0.0

8 years ago

0.3.3

8 years ago

0.3.2

8 years ago

0.3.1

9 years ago

0.2.0

9 years ago

0.1.2

9 years ago

0.1.1

9 years ago

0.1.0

9 years ago

0.0.1

10 years ago

0.0.0

10 years ago