Sublime Text several plugins

Source: Internet
Author: User
Tags sublime text

Save yourself for later use: http://blog.csdn.net/nivana999/article/details/7823805

1, Sublime text implementation vim command format (vintage plug-in is the plug-in, default is ignored)

Select, setting user, add a command:

" ignored_packages ": []

In default settings mode, the vintage plugin is ignored because the default profile under sublime Text3 does not support modification, so it can only be overridden under User Configuration.
// This command modifies the default mode to command-line mode. " Vintage_start_in_command_mode " true

2, Sublimelinter

You have to learn to be lazy in everything you do, and so is code. Although the Grunt tool provides a plug-in for jshint to check the JS code, this is a bit of hindsight. How do you lock and destroy errors when you code? Fortunately, the use of submlime Children's shoes is blessed. Sublimelinter is one such tool that provides code detection.

Preparatory work

Install Sublime Text Package management tool: Http://wbond.net/sublime_packages/package_control

Install Sublimelinter:https://github.com/sublimelinter/sublimelinter using the Sublime Text Package management tool

(Note that you can install with the Package management tool, or you can download the Sublimelinter tool directly from Git, unzip the file into the Packages folder, half the path is: C:\Users\admin\AppData\Roaming\Sublime Text 3\packages)

Installing node. js, we recommend that you install the Windows Installer version: http://nodejs.org

Parameter configuration

Open the Sublimelinter configuration file, Preferences->package Settings->sublimelinter->settings-user, for the following configuration:

{    "Sublimelinter":"save-only",    "Sublimelinter_popup_errors_on_save":true,    "Sublimelinter_executable_map": {        "JavaScript":"D:/program Files/nodejs/node.exe",        "CSS":"D:/program Files/nodejs/node.exe"    },    "jshint_options": {        "Strict":false,        "Quotmark":" Single",//only single quotes can be used        "Noarg":true,        "Noempty":true,//empty statement block {} is not allowed        "Eqeqeq":true,//!== and = = = Check        "undef":true,        "Curly":true,//when the value is true, you cannot omit the curly braces after the loop and conditional statements        "Forin":true,//For in hasownpropery check        "devel":true,        "jquery":true,        "Browser":true,        "WSH":true,        "Evil":true,        "Unused":"VARs",//Parameters and variables not used check        "Latedef":true,//define variables first, then use        "Globals": {            "Grunt":true,            "Module":true,            "window":true,            "JQuery":true,            "$":true,            "Global":true,            "Document":true,            "Console":true,            "SetTimeout":true,            "setinterval":true        }    },    "csslint_options": {        "adjoining-classes":false,        "box-sizing":false,        "Box-model":false,        "compatible-vendor-prefixes":false,        "Floats":false,        "font-sizes":false,        "gradients":false,        "Important":false,        "known-properties":false,        "Outline-none":false,        "qualified-headings":false,        "regex-selectors":false,        "Shorthand":false,        "text-indent":false,        "unique-headings":false,        "Universal-selector":false,        "unqualified-attributes":false    }}

Description under:

Sublimelinter operating mode, a total of four kinds, the meaning is as follows:

    • True-instant validation in the background when user input;
    • False-The checksum is only performed at initialization time;
    • "Load-save"-check when the file is loaded and saved;
    • "Save-only"-Verify when the file is saved;

Recommended set to "Save-only", so only after writing code, save the time to verify, Sublime Text run will be more fluent.

Configure JavaScript and CSS to use the JS Engine (node. js) for the installation path.

Sublimelinter uses jshint as the default JavaScript validator, and can also be configured as JSLint and Gjslint (Closure linter). The following I use the Jshint check option, you can according to their own coding style configuration, the meaning of the options can be referred to here: http://www.jshint.com/docs/#options

Sublimelinter uses csslint as the validator for the CSS, the following is the default configuration of the check option, can be modified according to the personal coding style.

Sublime Text several plugins

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.