CSDN阅读优化

去除CSDN网站的阅读限制和广告

目前為 2023-04-25 提交的版本,檢視 最新版本

// ==UserScript==
// @name         CSDN阅读优化
// @namespace    http://tampermonkey.net/
// @version      1.0
// @author       libaofeng
// @description  去除CSDN网站的阅读限制和广告
// @match        https://blog.csdn.net/*
// @grant        none
// @license      MIT
// ==/UserScript==

(function() {
    'use strict';

    // 获取文章内容元素,并删除内联样式属性
    var article_content = document.getElementById("article_content");
    if (article_content) {
        article_content.removeAttribute("style");
    }
    // 删除提示登录(不可用)/注册(不可用)的元素
    var follow_text = document.getElementsByClassName('follow-text')[0];
    if (follow_text) {
        follow_text.parentElement.parentElement.removeChild(follow_text.parentElement);
    }
    // 删除弹出框
    var hide_article_box = document.getElementsByClassName(' hide-article-box')[0];
    if (hide_article_box) {
        hide_article_box.parentElement.removeChild(hide_article_box);
    }

})();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址