Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » Imposible to select the classes methods with Eclipse Neon JSDT
icon5.gif  Imposible to select the classes methods with Eclipse Neon JSDT [message #1740191] Wed, 10 August 2016 09:28 Go to next message
Xavier Ottolini is currently offline Xavier OttoliniFriend
Messages: 4
Registered: April 2016
Junior Member
Hi,

I have just installed the latest Eclipse Neon JSDT edition. I have imported an old javascript project developped in Ecmascript 5. My project uses the asynchronous module definition API RequireJS to import sources.

When I open the Outline view, I see only the classes names but not the methods names. In the same way, when I press on Ctrl+O, I do not see any methods names. This is a problem because if I can not select directly the methods names I spend much more time.

Here is a example of class.

define([
	"jquery",
	"pubsub/pubsub",
	"app/constant",
	"app/utils/module-utils"
], function($, PubSub, constant, moduleUtils) {

	"use strict";
	
	/**
	 * Constructor initializes variables
	 */
	function Controller() {
		var that;
		that = this;
		that.shown = false;
		that.subscribers = [];
	};
	Controller.prototype.show = function() {
		var that;
		that = this;
		that.shown = true;
	};
	
	Controller.prototype.hide = function() {
		var that;
		that = this;
		that.shown = false;
	};
	return Controller;
});


Can someone tell me if there is a setting to allow to select the classes names ? Otherwise, is it necessary to download another plugin ?

Regards,

Xavier
icon3.gif  Re: Imposible to select the classes methods with Eclipse Neon JSDT [message #1740195 is a reply to message #1740191] Wed, 10 August 2016 09:59 Go to previous messageGo to next message
Xavier Ottolini is currently offline Xavier OttoliniFriend
Messages: 4
Registered: April 2016
Junior Member
Hi all!

I have found a solution in this page : http://stackoverflow.com/questions/27906867/eclipse-supporting-outline-view-with-require-js-define

The problem is that Eclipse JSDT is not compliant with RequireJS. In the Tern project, there is a Tern Outline which is able to view the methods even if I use RequireJS.

I have installed the Tern plugin by using the repository : http://oss.opensagres.fr/tern.repository/1.2.0/
I open the Tern Outline in the Window / Show view / Other menu. In the Javascript section, select Tern Outline.

Regards,

Xavier
Re: Imposible to select the classes methods with Eclipse Neon JSDT [message #1740290 is a reply to message #1740195] Thu, 11 August 2016 08:50 Go to previous message
Xavier Ottolini is currently offline Xavier OttoliniFriend
Messages: 4
Registered: April 2016
Junior Member
Hi !

I have tested the Tern plugin. I am not completely satisfied by it. There are many libraries in my project. For that reason, the auto-complete feature does not work with Tern. More over, when there are several classes in my file, the Tern Outline does not display anything.
Previous Topic:Java on Eclipse calculator issue
Next Topic:Reclaiming vertical space in Eclipse's default themes
Goto Forum:
  


Current Time: Fri Apr 19 22:01:18 GMT 2024

Powered by FUDForum. Page generated in 0.07807 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top