4 How to Use

4.1 LibreJS in action

After installing the add-on, you will see the LibreJS widget in the add-on bar at the top right of the browser window. After loading a page, left-click on the widget to view the deactivated JavaScript code from the page (both on page and external) and, if applicable, the scripts that were accepted.

4.2 Script Blacklist/whitelist

Scripts may be blacklisted or whitelisted through the pop-up menu box.

Whitelisted scripts will always be accepted and blacklisted scripts will always get rejected.

It is important to note that this feature recognizes which scripts are blacklisted and whitelisted based on hash. This means that even a slight difference in a script’s code will cause it to be recognized as a separate script.

Sometimes, JavaScript will be dynamically generated so that it is different every time a website is loaded. These types of scripts cannot be whitelisted or blacklisted since they cannot be recognized.

LibreJS has a default whitelist of scripts that are known to be free but may not declare their license in a format that LibreJS can understand.

4.3 Complaint Feature

It is very important to complain when a site has nonfree JavaScript code, especially if it won’t work without that code. LibreJS makes it easy to complain by heuristically finding where to send the complaint.

When nonfree/nontrivial code is detected in a page, LibreJS attempts to find a relevant contact link or email for the website you are visiting. In order to do so, it will attempt to visit a few links from the current page (for instance, a link labeled “contact” on the same domain as the current page, …)

LibreJS detects contact pages, email addresses that are likely to be owned by the maintainer of the site, Twitter and identi.ca links, and phone numbers.

When you complain to the website for their nonfree nontrivial JavaScript, provide them with the link to the JavaScript Trap essay so that they can get more information on what the issue is and how they can solve it on their own site.

LibreJS includes a default subject line and body for the complaint email, with a link to the JavaScript Trap essay. This can be configured in the LibreJS add-on preferences in your web browser.

4.4 Options

You can manage LibreJS’s preferences either from the extension’s entry in your browser’s Add-ons Manager page (about:addons) or by clicking the LibreJS toolbar icon and then the "Settings..." button on the top right of the popup. This will open a panel containing a whitelist/blacklist manager and a section to configure your complaints messages to site owners.

Whitelist/Blacklist

LibreJS lets you whitelist or blacklist domain names and subdomains, to bypass the regular JavaScript checks. This might be useful, for example, if you are running your own code in a local web server, or if you don’t want to waste computing resources on script origins you already know you can’t trust. librejs provides a lists manager UI to handle both the lists on the top of its Options panel.

Complaint email subject

Configure the default subject used in complaint emails.

Complaint email body

Configure the default body used in complaint emails.