I have been working on the exact same file directory with eclipse for many years. It just worked. I am using PHP, CSS, JS, HTML files.
Occasionally, I ran an automatic upgrade as described here. This also just worked.
Now after the latest upgrade, several things just stopped working:
In PHP files, the core commands are not auto-completed anymore. I searched for a solution, to no avail.
Javascript files don't get any special editor anymore.
Now my most pressing question is:
Where do I re-enable the good old Javascript editor?
Here's my Installation details:
The Eclipse IDE for PHP Developers is made up of components from various Eclipse projects. In the Eclipse IDE 2020-06 release the JavaScript support for .js file is no longer provided by the JavaScript editor from JSDT, but by Eclipse Wild Web Developer.
Wild Web Developer does not provide a separate Editor for JavaScript, but extends the Generic Text Editor by code completion, syntax highlighting, validation, navigation, etc. for JavaScript.
To get back the JSDT JavaScript editor you have to uninstall Eclipse Wild Web Developer and install JavaScript Development Tools from the Eclipse IDE 2020-03 release (I guess the problems if you had both were solved by simply removing or disabling the JavaScript editor in the 2020-06 release):
Uninstall Eclipse Wild Web Developer: In Help > About Eclipse IDE: Installation Details, in the Installed Software tab select Eclipse Wild Web Developer and click Uninstall...
Install JavaScript Development Tools from the 2020-03 release: In Help > Install New Software... work with https://download.eclipse.org/releases/2020-03 and choose JavaScript Development Tools to install
See also Eclipse IDE 2020-06 > New & Noteworthy > Eclipse PHP Development Tools
Had the same issue, using 2020-09. I found that Wild Web Developer (in Help > Eclipse Marketplace..) was indeed installed, but then I checked more info and it said
To see it in action, open the desired file with the Generic Editor that's included by default in the Eclipse IDE.
and when I opened the javascript file in the Generic Editor, I get all the fancy I need...
go to Window -> Preferences then type file associations then select *.js on the right side list, then select "Generic Text Editor" below and click "Default" button
Yes versions above 2020-05 works with General Editor as default editor for JS files in eclipse
Window--> Preferences --> File Associations --> Select (*.js) and then select Generic Editor
Related
I already have Eclipse IDE for JAVA Developers, and have different projects created for Cucumber/JAVA. I want to create a project for Javascript now, but I am not getting the option in New Project, I tried installing Plugins too but it did not worked for me.
Can someone please help. I am new to Javascript.
Is it possible to do so without having to install another eclipse? I have my projects in the previous one which i don't want to loose. I tried installing previous version of eclipse for Eclipse Javascript but I am not able to do so and the only one i see is Eclipse IDE again.
Install https://marketplace.eclipse.org/content/eclipse-web-developer-tools-0 , and then work with your JavaScript files using the Generic Text Editor. No project wizard or type is required.
First go to help>marketplace and search for javascript plugin and install it.
After installation you can find an option here,
I can't really reproduce the issue, but no highlighting or intellisense is working in .js files, it works just fine in .json files however.
The default editor for .js files is JSON Editor.
I tried safe-mode, disabling all extensions, resetting all settings, and I even reinstalled the IDE (repair), but the issue still persists.
I will add, that when I launch the IDE and a JS file is open on scope, I get the following error message (highlighting and intellisense don't work anyway):
The 'JavaScriptWebExtensionPackage' package did not load correctly.
The problem may have been caused by a configuration change or by the installation of another extension. You can get more information examining the file 'C:\Users\Shimmy\AppData\Roaming\Microsoft\VisualStudio\14.0\ActivityLog.xml'.
Restarting Visual Studio could help resolve the issue.
Continue to show this error message?
Here you can view the ActivityLog.xml file, I pasted in some of the recent lines I think might be relevant:
<entry>
<record>188</record>
<time>2015/08/14 13:00:57.332</time>
<type>Information</type>
<source>VisualStudio</source>
<description>Begin package load [JavaScriptWebExtensionsPackage]</description>
<guid>{30DB8F9B-EC9F-44D6-B377-83C7C27A1A8B}</guid>
</entry>
<entry>
<record>189</record>
<time>2015/08/14 13:00:57.394</time>
<type>Error</type>
<source>VisualStudio</source>
<description>SetSite failed for package [JavaScriptWebExtensionsPackage]</description>
<guid>{30DB8F9B-EC9F-44D6-B377-83C7C27A1A8B}</guid>
<hr>80131500</hr>
<errorinfo>Expected 1 export(s) with contract name "Microsoft.VisualStudio.JavaScript.Web.Extensions.ReferenceAutoSync.IReferencesFilePathProvider" but found 0 after applying applicable constraints.</errorinfo>
</entry>
<entry>
<record>190</record>
<time>2015/08/14 13:00:57.394</time>
<type>Error</type>
<source>VisualStudio</source>
<description>End package load [JavaScriptWebExtensionsPackage]</description>
<guid>{30DB8F9B-EC9F-44D6-B377-83C7C27A1A8B}</guid>
<hr>80131500</hr>
<errorinfo>Expected 1 export(s) with contract name "Microsoft.VisualStudio.JavaScript.Web.Extensions.ReferenceAutoSync.IReferencesFilePathProvider" but found 0 after applying applicable constraints.</errorinfo>
</entry>
I found answer here: Visual Studio 2015 RTM - Lost JavaScript support after update TypeSript Tools
These are the steps to fix it:
If the “Universal Windows App Development Tools” are still installed:
Go to Programs and Features, select Visual Studio 2015, click Change.
In Visual Studio setup, click Modify.
Deselect the feature “Universal Windows App Development Tools”
Select “Universal Windows App Development Tools” again, and click Update.
If you have already uninstalled the “Universal Windows App Development Tools”:
Reinstall “Universal Windows App Development Tools”
Or, take the following steps to reinstall the JavaScript project system and language service:
Download the installer for your edition of Visual Studio, e.g., vs_community.exe.
Open a CMD window, and run the following command: vs_community.exe /modify /installselectableitems JavaScript_Hidden /passive
I've followed the first steps and got back Javascript support.
Hope this helps
-UPDATED-
After I did the above steps, almost everything was working, except that I got an error message every time I opened a .js file, the following did the trick:
My guess is that only reinstalling the SDK didn't update the MEF cache. You can do this manually by following these steps:
Open a command prompt as administrator
CD into C:\Program Files (x86)\Microsoft Visual Studio
14.0\Common7\IDE
Run devenv /updateconfiguration
Run devenv /clearcache
That got rid of the last error, and everything is working fine.
Source: https://github.com/Microsoft/TypeScript/issues/4238
The issue seems to be fixed on Update 1. I'm on the professional version but I imagine that it applies to all versions.
To be clear, Intellisense was not working for me for css related stuff on razor files and post update 1 it seems to be working.
I know this question is clearly targeting Visual Studio 2015.
However, I wanted to put my two cents in for those who desperately tried out if the accepted answer also works for Visual Studio 2017.
In my case, the loss of syntax highlighting was caused by the new javascript language service. I got it back right after deselecting the following checkbox and restarting Visual Studio:
Tools > Options > Text Editor > JavaScript/TypeScript > Language
Service > Enable the new JavaScript language service.*
Reference: https://developercommunity.visualstudio.com/comments/34109/view.html
I am new to Eclipse - inherited unfinished project after employee who left. I downloaded war file and by trial and error installed missing components till it actually built app. I can edit java files, but when I try to open java script files, I get error:
Could not open visual page editor
no more handles
could not load SWT library
no swt-xulrunner-gtk-4234 in java.library.path
Linux Fedora 17, Eclipse Juno, SWT is reported as installed by yum. ~/.swt/lib/ is empty
It looks like you do not have the proper library to load browser widgets in your Eclipse, that is what swt-xulrunner refers to. This FAQ should help you.
What it is saying is that you need to start Eclipse with the following system property:
-Dorg.eclipse.swt.browser.XULRunnerPath=<path_to_xulrunner>
There should be a xulrunner already included in your Eclipse, but if not, you will need to download a new one from here.
Also, it could be that you are using the Ubuntu pre-packaged Eclipse. I would avoid doing that. This pre-packaged eclipse often has some missing things in it. I'd instead recommend downloading directly from Eclipse.org
I have installed JavaScript Development Tools Plugin for Eclipse, but i am not able to run or debug a JavaScript Project.
I want to debug using the inbuilt Rhino Interpreter, not using a web browser.
I have created a JavaScript project and when I try to create a run configuration, it says "Please select a valid project" and the run button is greyed out..
Please view the attached snapshot.
Which version of eclipse are you using? Install Eclipse 3.7 Java EE Version, there you could directly right click on the javascript file (.js extension) and Debug As -> Rhino JavaScript. Please see the attached image.
The Debug configuration will look as below. There will not be any browse for project, you need to browse directly javascript file as shown in below image (you can browse all the javascript files from the entire workspace).
Apparently you didn't create a valid javascript project. Depending on your Eclipse version, this is for Juno, go to File - New - Javascript Project.
Javascript projects don't have a "nature" associated with them that let you know in the Project Explorer. Spring, Java, or even Perl projects have this in eclipse. It's a symbol assigned to a project that lets Eclipse know what type of project it is. Java projects have a "J", Spring projects have an "S".
How to enable Aptana 3 features like code assist, debugger etc for Java project in eclipse?
I want to add these features to existing project (not creating new one).
You can try to 'hack your way in'. I did not try this one, but it might just work, since the Studio looks for the project 'Natures' to determine how to operate.
Create an Aptana Studio Web Project and then go to the created folder on your disk and look for the .project file. Open the file and look for the 'natures' and the 'builders' element.
Copy those into the .project file of your Java project and start the Studio.
Once the project has the Aptana Natures, you might be able to add/remove Natures using the project's 'Properties' dialog ('Project Natures' item).
Hope that helps ;)