utils/moduleVisitor.js
function checkCommon(call) {
    if (call.callee.type !== 'Identifier') return
    if (call.callee.name !== 'require') return
    if (call.arguments.length !== 1) return

    const modulePath = call.arguments[0]
    if (modulePath.type !== 'Literal') return
    if (typeof modulePath.value !== 'string') return

    checkSourceValue(modulePath, call)
  }
function checkCommon(call) {
    if (call.callee.type !== 'Identifier') return
    if (call.callee.name !== 'require') return
    if (call.arguments.length !== 1) return

    const modulePath = call.arguments[0]
    if (modulePath.type !== 'Literal') return
    if (typeof modulePath.value !== 'string') return

    checkSourceValue(modulePath, call)
  }
function checkCommon ( call ) { if ( call . callee . type !== 'Identifier' ) return if ( call . callee . name !== 'require' ) return if ( call . arguments . length !== 1 ) return const modulePath = call . arguments [ 0 ] if ( modulePath . type !== 'Literal' ) return if ( typeof modulePath . value !== 'string' ) return checkSourceValue ( modulePath , call ) }
for CommonJS `require` calls adapted from @mctep: http://git.io/v4rAu
for CommonJS require calls adapted from