IntelliJ Idea 12 Unable To Resolve Express Methods - node.js

For some odd reason, I can't seem to have code completion with the "express" object in my node.js project. Here is a screen of it.
My OS is Windows 8 and I am using IntelliJ Idea 12.11. Perhaps I need to do some extra setup? Please let me know.

#CrazyCoder got it right, it is indeed a intellij bug, as of now still unpatched, guess we have to wait =( The URL is http://youtrack.jetbrains.com/issue/WEB-6667. In the meantime, I guess I will have to live with it.

if you are on IDEA 13, you will still not get the Express methods until you use the express typescript stub
go to Javascript Libraries > Downloads and switch the combobox at the top to Typescript community stubs then type express
you should see the stub, it's also here:
https://github.com/borisyankov/DefinitelyTyped/blob/master/express/express.d.ts
if you are on Java 1.7 and haven't disabled the SNI Support you will get a handshake alert and the download will fail, go to the directory where your IDEA.exe is located and add the following line to the idea.exe.vmoptions:
-Djsse.enableSNIExtension=false

Related

Cannot GET / error

looked for couple of hours, on how to solve that, but no luck.
I am using VS 2017 preview edition, and trying to open ASP.NET core 2.0 web application, that uses Angular template
when i open the site (f5 or ctrl-f5), the web-browser getting opened with the message
Cannot GET /
I don't know what causing that and how to fix that, tried to clean/rebuild/restart VS/change project port number/restart the computer, what else can I do to solve that?
Depending on what error you have in the client application, the server might not start at all. Local errors like undeclared locals are seldom a problem.
Usually, the web server does not start when a dependency of the module marked as bootstrap is missing, like, for example `entryComponents'.
Another thing that can cause the boostrap to fail, is a missing file: in this case you should have a look at templateUrl and styleUrls.
Manually compiling via ng build (or better ng build --prod) will point you to the offending code.

issue with extension library value picker in xpages (extlib.SampleDataUtil)

I am having issue with value picker of extension library. When i use java file exitlib/pickers/SimplePicker.java system shows following errors.
i) SampleDataUtil cannot be resolved
ii) The import exitlib.SampleDataUtil cannot be resolved
I have gone through a thread on internet that in application properties advanced tab i have to check following 2 options
com.ibm.xsp.extlib.library
com.ibm.xsp.extlibx.library
but these options are not available to me. Can anybody guide me where I am having issue in implementing extension library.
Thanks in advance
It sounds like things are possibly not installed correctly....
Try tell http osgi ss com.ibm.xsp.extlibx on the server console to see if it is resolved.
If not, the installation hasn't worked correctly on the server.
Another option is you haven't installed in designer?
The below is a good reference for installing on both server and client
http://www.tlcc.com/admin/tlccsite.nsf/pages/extension-lib

Using Mongoose with IntelliJ IDEA Causes Unresolved Function or Method

I just downloaded the 30-day trial of IntelliJ IDEA Ultimate Edition and I'm having an issue with the Node.js project I imported.
I am using Mongoose and am using the find and findById methods of my model classes fairly often. Since these methods are provided by mongoose and not actually defined explicitly in my model classes, IntelliJ does not seem to like them. Everywhere that I use the methods, I get an error saying "Unresolved function or method xxx".
I have read several other users stating they had similar issues with Node and WebStorm, but those all seemed to be with the code Node library and all of the answers said to use the Node.js Globals library. I have imported this library and tried downloading both mongodb-DefinitelyTyped and mongoose-DefinitelyTyped from the Libraries screen, and still cannot get the warnings to go away.
I decided it was probably faster to contact JetBrains support since I didn't seem to be getting any quick solutions here. I guess this issue is a bug with IntelliJ IDEA 14 because they had me try the IntelliJ IDEA 15 EAP and it worked fine.
So I guess the solution is to go EAP or just wait for 15 if anybody else has this issue.

Using NodeJS module in Titanium Studio

All, I am trying to using third party NodeJS SDK in Titanium Studio. However, I consistently encounter dependency issues, such as util.js, utils.js, ms.js, events.js etc. I tried to add the missing module manually, but it looks like it will become un-tractable as there are so many dependencies.
My questions are :
1. Is that possible to use NodeJS based SDK in Titanium Studio .
2. If so, what is the right approach to include the dependencies.
Thanks a lot!
Titanium can't get Coffee scripts to work natively (assuming you want to deploy the TitaniumWrapper.coffee). A possible solution you may want to try is hooking a plugin http://billdawson.com/titanium_coffee_script/ in order to pre-compile Coffee scripts.
You can also try to embed everything using a Tiwebview that wraps HTML to load mojio-js.js but you would still need to observe events mojio client (like replacing keys, login an user and create a few model instances).
Hope you find the info useful and can serve for further research.

Trouble loading node_modules in Intellij idea ultimate

I am able to get up and running with nodejs by following the steps in this tutorial
http://blog.jetbrains.com/webide/2011/11/webstorm-your-node-app/
However, I am not able to load any modules while running through the ide. The debugger just blows up at the line
express = require("express");
Please note that I have all the modules installed locally(node_modules directory under root of project directory) and not globally.
FYI, I am able to run the same from the command prompt, just not through intellij.
Please note, I am using node 0.6.6. I am running on Ubuntu 11.10 x64.
Thanks
-Venu
I have a suggestion how you may proceed.
First let me describe the problem, then the workaround, then the proposal to get this addressed.
Problem
Blow up at require("express")
Reason
By default intellij will suspend upon any exception. See the breakpoint rule.
You got stuck at the exception.
The exception, in this case, is due to the fact that module.js is trying to resolve the "express". It actually forms different paths and filenames (see logic in module.js, starting line 159).
Because not all permutations of paths and filenames formed properly, exception is thrown at fs.statSync() fs.js 414 just because that path/filename does not exists.
Workaround
Turn off break at all exceptions when startup/loading modules. Turn it back on when your server is running.
Proposal
next iteration of node.js library handles package/module resolution more elegantly? Let me see if there's a bug being filed already.

Resources