Skip to content

Tern & Node.js support

Angelo edited this page Sep 9, 2015 · 9 revisions

tern.js provides the node Tern plugin which gives a support for Node.js.

After installing and converting your project as Tern Project, go at Tern project property, click on Tern / Modules item and select the node tern plugin :

Check Node Plugin

After that you can benefit with Node.js completion on require :

Require Completion

and completion for module :

node.js completion module

Tern is able to know the module of the require and if you write require('fs'), you can benefit from fs functions completions :

FS Completion

Tern is able to know the type of the function argument and you can benefit from err functions completion :

error

Node Lint

If you select Node lint, you can benefit with validation for require module :

node lint

Clone this wiki locally