Eclipse completely removes validation (completely solves the problem of stuck editing js files)

The default JS editor in Eclipse is very slow, especially when copying and pasting code, the CPU usage is always high or even 100%, which makes editing very stuck.

This is caused by the Validate function in Eclipse. This tasteless function is simply maddening.

I tried to modify the corresponding configuration items of Validation in the menu and project properties, but it did not work. Finally, I found that the .project file in the root directory of the project needs to be modified to completely solve the problem of editing JS files.

<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
    <name>integrate-base-web</name>
    <comment></comment>
    <projects>
    </projects>
    <buildSpec>
        <buildCommand>
            <name>org.eclipse.ui.externaltools.ExternalToolBuilder</name>
            <triggers>full,incremental,</triggers>
            <arguments>
                <dictionary>
                    <key>LaunchConfigHandle</key>
                    <!-- <value><project>/.externalToolBuilders/org.eclipse.wst.jsdt.core.javascriptValidator.launch</value> -->
                </dictionary>
            </arguments>
        </buildCommand>
        <buildCommand>
            <name>org.eclipse.jdt.core.javabuilder</name>
            <arguments>
            </arguments>
        </buildCommand>
        <buildCommand>
            <name>org.eclipse.wst.common.project.facet.core.builder</name>
            <arguments>
            </arguments>
        </buildCommand>
        <buildCommand>
            <name>org.eclipse.ui.externaltools.ExternalToolBuilder</name>
            <triggers>full,incremental,</triggers>
            <arguments>
                <dictionary>
                    <key>LaunchConfigHandle</key>
                    <!-- <value><project>/.externalToolBuilders/org.eclipse.wst.validation.validationbuilder.launch</value> -->
                </dictionary>
            </arguments>
        </buildCommand>
        <buildCommand>
            <name>org.eclipse.m2e.core.maven2Builder</name>
            <arguments>
            </arguments>
        </buildCommand>
    </buildSpec>
    <natures>
        <nature>org.eclipse.jem.workbench.JavaEMFNature</nature>
        <nature>org.eclipse.wst.common.modulecore.ModuleCoreNature</nature>
        <nature>org.eclipse.jdt.core.javanature</nature>
        <nature>org.eclipse.m2e.core.maven2Nature</nature>
        <nature>org.eclipse.wst.common.project.facet.core.nature</nature>
        <!-- <nature>org.eclipse.wst.jsdt.core.jsNature</nature> -->
    </natures>
</projectDescription>

The comment part in the code posted above is the part of the Validation configuration item to be removed.

After removing it, the whole world is clean.

 

"It turned out that after holding back for a while, I really stopped contacting."

Reprinted in: https://www.cnblogs.com/yanggb/p/11528281.html

Guess you like

Origin http://43.154.161.224:23101/article/api/json?id=324741640&siteId=291194637
Recommended