Hmmm... you could also do like
var NodeBeeline = require('beeline');
and keep the externs as you had them originally... I wonder if that'll work.
-ilia
var bee = /** @alias {NodeBeeline} */ (require ... )
or even
/** @alias {NodeBeeline} */
var bee = require(...);
Or something like that (@namespace perhaps?). I think using type here
would be a hack, since NodeBeeline is not a type, nor do you really
want or need to treat it like one.
-ilia
It basically just needs a proposal spec that sorts out the various
tricky cases (e.g., what happens when NodeBeeline is assigned to a
different anonymous object? would the type name point to the new
object? or to the old one? or would using this annotation just imply
@const?)