• sublime jshint插件安装


    下面是在sublime上配置jshint代码检查的详细步骤。
     
    1、安装nodejs。下载地址:http://nodejs.org/download/
    2、在控制台安装jshint:$ npm install jshint -g
    3、在sublime安装sublimelinter
    4、在sublime安装jshint
    5、配置sublimelinter:preference-package setting-sublimelinter-user
    {
      "sublimelinter": "save-only",
       "jshint_options":
        {
            // To fix column positions for JSHint errors you may want to add `"indent": 1` to your
            // **User** "jshint_options". This issue affects users with tabs for indentation.
            // This fix was reverted due to a conflict with using the `"white": true` option.
            // "indent": 1,
            // 设置 JS 执行环境为浏览器
            "browser": true,
             // 加载 jQuery 的全局变量(jQuery、$)
            "jquery": true,
            //禁止下划线的变量名
            "nomen":true,
             // 行尾不要分号,false表示强制需要分号结尾
            "asi": false,
            "white":true,
            // 其他全局变量,我用了 SeaJS
            "predef": [
                 "define",
                 "seajs",
                 "console"
                 ]
        },
        "sublimelinter_executable_map":
    {
        "javascript":"C:/Program Files/nodejs/node.exe",
        "css":"C:/Program Files/nodejs/node.exe"
    }
    }
  • 相关阅读:
    python网络爬虫——scrapy核心组件介绍、请求传参、下载中间件
    python网络爬虫——Scrapy全站数据爬取【手动请求发送】及post请求的发送
    python网络爬虫——scrapy框架持久化存储
    php常见排序
    php实现快速排序
    mysql读写分离 主从同步
    php预定义字符
    本地Navicat连不上Linux虚拟机MySQL数据库问题
    php yii 命令
    yii 定义场景
  • 原文地址:https://www.cnblogs.com/liubingna/p/4174416.html
Copyright © 2020-2023  润新知