instead of displaying the relative files in the required modules list typing . commits the session if the user haven't typed ' or "
Comments: We inadvertently set ourselves up here by starting require-completion (i.e. the list of modules) as soon as `(` is typed. The problem is that the argument of `require()` is not necessarily a literal string - it may well be an expression, and in that case what's typed between the parens is JS code, not module name. So JS intellisense and require intellisense start fighting over who's in control, and it's not clear which one should win at any given point (and rather complicated to wire it up even if you could decide). Note though that if you explicitly type the opening quote for the module name - i.e. `require('` - then we know that you're now _inside_ a string literal, and so the only kind of completion that's valid there is the require-completion. So in that case, typing `.` will in fact do exactly that, select the first of the relative modules in a list. And typing `/` is not triggered as completion trigger either, the way it is in normal JS code. So this bug is strictly about the case where one types `require(` without an opening quote and then tries to use the completion list.
Comments: We inadvertently set ourselves up here by starting require-completion (i.e. the list of modules) as soon as `(` is typed. The problem is that the argument of `require()` is not necessarily a literal string - it may well be an expression, and in that case what's typed between the parens is JS code, not module name. So JS intellisense and require intellisense start fighting over who's in control, and it's not clear which one should win at any given point (and rather complicated to wire it up even if you could decide). Note though that if you explicitly type the opening quote for the module name - i.e. `require('` - then we know that you're now _inside_ a string literal, and so the only kind of completion that's valid there is the require-completion. So in that case, typing `.` will in fact do exactly that, select the first of the relative modules in a list. And typing `/` is not triggered as completion trigger either, the way it is in normal JS code. So this bug is strictly about the case where one types `require(` without an opening quote and then tries to use the completion list.