title: Node-Webkit and AngularJS package apps: require not defined
body: <p>I am using <a href="https://github.com/mllrsohn/grunt-node-webkit-builder" rel="nofollow">https://github.com/mllrsohn/grunt-node-webkit-builder</a> to package my node-webkit app which is built using AngularJS.</p>
  
  <p>The app works fine on MAC when I <a href="https://github.com/rogerwang/node-webkit/wiki/Debugging-with-Sublime-Text-2-and-3" rel="nofollow">build from Sublime Text</a>. But when I package the app using any packaging tool, I get the error saying "require is not defined". What am I missing?</p>
  
  <p>For more context, I have a services layer which is written in Node.js using express. The Angular project calls Node.js APIs and renders the content. I am using a SQLite3 DB. Which is the best way to package such apps? I am alright with writing an installer starts Node.js server separately.</p>