what does it mean by “debug = require('debug')('api:server')”
问题 I was reading some code of a project to learn node.js then I found this line ( debug = require('debug')('api:server') ) which is enclosed in brackets. As I'm new to programming and when I don't know something I just search it on the web, but I couldn't find an answer for this one. If you are going to tell me to search on the web more aggressively then please tell me HOW too. 回答1: require returns the exports of some other module. Here, since debug is being passed into require , the debug