From 13db12ce5c9cfe0c433f35587035dce15eedf294 Mon Sep 17 00:00:00 2001 From: Peter Bengtsson Date: Mon, 26 Jul 2021 15:31:56 -0400 Subject: remove link 'title' attributes that's just the 'href' (zh-cn) --- files/zh-cn/tools/browser_console/index.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'files/zh-cn/tools/browser_console/index.html') diff --git a/files/zh-cn/tools/browser_console/index.html b/files/zh-cn/tools/browser_console/index.html index 74fe0b0629..38742a9e50 100644 --- a/files/zh-cn/tools/browser_console/index.html +++ b/files/zh-cn/tools/browser_console/index.html @@ -108,7 +108,7 @@ clearBtn.addEventListener('mouseover', function() {

Bonus Features Available

-

For Add-on SDK add-ons, the console API is available automatically. Here's an example add-on that just logs an error when the user clicks a widget:

+

For Add-on SDK add-ons, the console API is available automatically. Here's an example add-on that just logs an error when the user clicks a widget:

widget = require("sdk/widget").Widget({
   id: "an-error-happened",
@@ -122,13 +122,13 @@ function logError() {
   console.error("something went wrong!");
 }
-

If you build this as an XPI file, then open the Browser Console, then open the XPI file in Firefox and install it, you'll see a widget labeled "Error!" in the Add-on bar:

+

If you build this as an XPI file, then open the Browser Console, then open the XPI file in Firefox and install it, you'll see a widget labeled "Error!" in the Add-on bar:

Click the icon. You'll see output like this in the Browser Console:

-

For Add-on SDK-based add-ons only, the message is prefixed with the name of the add-on ("log-error"), making it easy to find all messages from this add-on using the "Filter output" search box. By default, only error messages are logged to the console, although you can change this in the browser's preferences.

+

For Add-on SDK-based add-ons only, the message is prefixed with the name of the add-on ("log-error"), making it easy to find all messages from this add-on using the "Filter output" search box. By default, only error messages are logged to the console, although you can change this in the browser's preferences.

浏览器控制台命令行

-- cgit v1.2.3-54-g00ecf