Baidu Tieba: No Login

View Baidu Tieba without login.

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @namespace   VA_i
// @version     4.0.0.20180814
// @grant       unsafeWindow
// @include     /^https?://(?:tieba\.baidu\.com|www\.tieba\.com)//
// @include     /^https?://dq.tieba.com//
// @run-at      document-start
// @name        Baidu Tieba: No Login
// @name:zh-CN  百度贴吧:不登录即可看贴
// @name:zh-TW  百度贴吧:不登入即可看貼
// @description View Baidu Tieba without login.
// @description:zh-CN 百度贴吧看贴(包括楼中楼)无须登录。
// @description:zh-TW 百度贴吧看貼(包括樓中樓)無須登入。
// ==/UserScript==

unsafeWindow.Object.freeze = null;

document.addEventListener('DOMContentLoaded', function (event) {
  try {
    unsafeWindow.PageData.user.is_login = 1;
  } catch (error) {
    //alert(error);
  }
}, true);