How to install?
emielvangoor opened this issue · comments
Hi,
How do I install tern.jsduck, I'm new to ternjs and I don't know where to start. I created a .tern-project file in my root directory. What do I need to do now? I installed JSDuck and I'm using ExtJS 6...
Thanks in advance..
tern-jsduck is used to generate tern plugin for CKEditor, ExtJS. If you wish do that:
- copy https://github.com/angelozerr/tern.jsduck/blob/master/plugin/ckeditor_4.4.7.js in your tern/plugin file sytem folder.
- declare in your .tern-project
{
"ecmaVersion": 6,
"libs": ["browser"],
"plugins": {
"ckeditor_4.4.7": {}
}
}
@angelozerr Thanks for your reply! I downloaded the extjs_5.0.0.js and placed it in the tern/plugin folder and created the .tern-project as you suggested
Now tern throws the following error:
/usr/local/lib/node_modules/tern/lib/def.js:243
if (/^fn\(/.test(spec)) for (var i = 0; i < type.args.length; ++i) (function
^
TypeError: Cannot read property 'length' of undefined
at parseType (/usr/local/lib/node_modules/tern/lib/def.js:243:58)
at passTwo (/usr/local/lib/node_modules/tern/lib/def.js:408:9)
at passTwo (/usr/local/lib/node_modules/tern/lib/def.js:426:11)
at passTwo (/usr/local/lib/node_modules/tern/lib/def.js:426:11)
at passTwo (/usr/local/lib/node_modules/tern/lib/def.js:426:11)
at passTwo (/usr/local/lib/node_modules/tern/lib/def.js:426:11)
at passTwo (/usr/local/lib/node_modules/tern/lib/def.js:426:11)
at passTwo (/usr/local/lib/node_modules/tern/lib/def.js:426:11)
at doLoadEnvironment (/usr/local/lib/node_modules/tern/lib/def.js:468:5)
at Object.exports.load (/usr/local/lib/node_modules/tern/lib/def.js:480:7)
Which version of ternjs are you using? With tern 0.17.0 and Eclipse IDE (tern.java), it works great.
I suggets you that you share your project.
@emielvangoor That's a TernJS issue I also encountered with version 0.18.0. See this issue ternjs/tern#733 (PR #734 has been proposed).
Florent
@emielvangoor please retry it, I have fixed the problem by waiting the fix of ternjs.