资源监视插件,之前试过 Distill Web Monitor ,这个程序员可以试试。

    chrome插件链接

    1、新建

    image.png

    image.png

    2、获取html示例

    1. {
    2. "type": "get",
    3. "url": "http://www.chinanews.com/scroll-news/news1.html",
    4. "dataType": "html",
    5. "timeout": 7000,
    6. }
    1. //queryResult
    2. //presetPageUrl isRefresh lastReturn
    3. var highlight = lastReturn.highlight;
    4. var popup = lastReturn.popup;
    5. var url = presetPageUrl;
    6. var content = lastReturn.content;
    7. var extra = lastReturn.extra;
    8. queryResult = $(queryResult).find('li:nth-child(1) > div.dd_bt > a').text();
    9. content = '更新到了 ' + queryResult;
    10. if (content != lastReturn.content) {
    11. highlight = true;
    12. popup = true;
    13. }
    14. return {'highlight':highlight,'popup':popup,'url':url,'content':content,'extra':extra};

    3、获取rss示例

    1. {
    2. "type": "get",
    3. "url": "https://www.423down.com/feed",
    4. "dataType": "xml",
    5. "timeout": 7000,
    6. }


    1. //queryResult
    2. //presetPageUrl isRefresh lastReturn
    3. var highlight = lastReturn.highlight;
    4. var popup = lastReturn.popup;
    5. var url = presetPageUrl;
    6. var content = lastReturn.content;
    7. var extra = lastReturn.extra;
    8. content = $(queryResult).find('title').eq(1).text();//1 标题
    9. if (content != lastReturn.content) {
    10. url = $(queryResult).find('link').eq(1).text();//2 详情链接
    11. highlight = true;
    12. popup = true;
    13. }
    14. return {'highlight':highlight,'popup':popup,'url':url,'content':content,'extra':extra};