This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Navigator doesn't display nothing for smoothie.js | ||
---|---|---|---|
Product: | javascript | Reporter: | Petr Pisl <ppisl> |
Component: | Editor | Assignee: | Petr Pisl <ppisl> |
Status: | NEW --- | ||
Severity: | normal | CC: | mbalin |
Priority: | P3 | ||
Version: | 8.2 | ||
Hardware: | PC | ||
OS: | Linux | ||
Issue Type: | DEFECT | Exception Reporter: |
Description
Petr Pisl
2017-02-23 13:00:33 UTC
The issue is happening whenever there is a anonymous function in the JS file and also if module.exports is used . IMHO NodeJsObjectInterceptor tries to recognized, whether the code can be a Node.js module. Node.js module in run-time is wrap up in to a function. So all variables and function, which are declared in global space are not public, but private for the module. Node.js module exposes public variables and methods through export. So the ide, should not offer the variables and function from global space. This is a reason, why the NodeJsObjectInterceptor hides them. But because of this wrapping of, while scanning for JsStructure it is not able to identify the underlying item under the wrap up function in case of anonymous function. e.g., in below JS, navigator will not display Util variable. var result = function() { var Util =10; exports.val = 10; return 20; }(); |