now exports assigned back to module.exports only when neccessary and __dirname, __filename globals available in the module
added minify build option