really?
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE HTML> | |
<html> | |
<head> | |
<title>taybles</title> | |
<style type="text/css"> | |
.fullwidth-table { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var name = "javascript.options.strict"; | |
require("sdk/preferences/service").set(name, false); | |
var self = require("sdk/self"); | |
// data URI encoding of "some content" | |
var dataUrl1 = "data:text/plain;charset=utf-8;base64,c29tZSBjb250ZW50"; | |
// data URI encoding of "some more content" | |
var dataUrl2 ="data:text/plain;charset=utf-8;base64,c29tZSBtb3JlIGNvbnRlbnQ=" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require("sdk/preferences/service").set("javascript.options.strict", false); | |
var { ActionButton } = require('sdk/ui/button/action'); | |
var { Toolbar } = require("sdk/ui/toolbar"); | |
var { Frame } = require("sdk/ui/frame"); | |
var button = ActionButton({ | |
id: "my-button", | |
label: "my button", | |
icon: { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var { Toolbar } = require("sdk/ui/toolbar"); | |
var { Frame } = require("sdk/ui/frame"); | |
var frame1 = new Frame({ | |
url: 'data:text/html;charset=utf-8,blah' | |
}); | |
var toolbar = Toolbar({ | |
title: "My toolbar", | |
items: [frame1] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var { ToggleButton } = require("sdk/ui/button/toggle"); | |
var toggle = ToggleButton({ | |
id: "my-button", | |
label: "my button", | |
icon: { | |
"16": "./firefox-16.png", | |
"32": "./firefox-32.png" | |
} | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var { ToggleButton } = require("sdk/ui/button/toggle"); | |
var button = ToggleButton({ | |
id: "my-button", | |
label: "default", | |
icon: { | |
"16": "./firefox-16.png", | |
"32": "./firefox-32.png" | |
}, | |
onClick: updateLabelForThisWindow |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var { ToggleButton } = require("sdk/ui/button/toggle"); | |
var { ActionButton } = require("sdk/ui/button/action"); | |
var toggleButton = ToggleButton({ | |
id: "my-toggle-button", | |
label: "toggle-default", | |
icon: { | |
"16": "./firefox-16.png", | |
"32": "./firefox-32.png" | |
}, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let mdnRequest = require("sdk/request").Request({ | |
url: "https://developer.mozilla.org/en-US/search.json?q=" + currentCssProperty + "&topic=css", | |
onComplete: showTheDocSummary | |
}); | |
mdnRequest.get(); | |
... | |
function showTheDocSummary(response) { |
To create add-ons for Firefox using the SDK, you'll first need to follow the instructions to install and activate the SDK. Installation is something you only need to do once: activation is something you need to do for each command prompt you open.
Once you've done that, you'll be looking at a command prompt.
If you're on Linux or Mac OS X, the prompt should start with the name of the SDK's root directory: