OLD | NEW |
1 <div id="pageData-title" class="pageData">Other APIs</div> | 1 <div id="pageData-title" class="pageData">Other APIs</div> |
2 | 2 |
3 <p> | 3 <p> |
4 In addition to the | 4 In addition to the |
5 <a href="api_index.html">chrome.* APIs</a>, | 5 <a href="api_index.html">chrome.* APIs</a>, |
6 extensions can use all the APIs | 6 extensions can use all the APIs |
7 that the browser provides | 7 that the browser provides |
8 to web pages and apps. | 8 to web pages and apps. |
9 If the browser doesn't support an API you want to use, | 9 If the browser doesn't support an API you want to use, |
10 you can bundle additional API libraries into your extension. | 10 you can bundle additional API libraries into your extension. |
11 </p> | 11 </p> |
12 | 12 |
13 <p>Here's a sampling of the APIs that extensions can use:</p> | 13 <p>Here's a sampling of the APIs that extensions can use:</p> |
14 | 14 |
15 <dl> | 15 <dl> |
16 <dt><strong> Standard JavaScript APIs </strong></dt> | 16 <dt><strong> Standard JavaScript APIs </strong></dt> |
17 <dd> These are the same core JavaScript and DOM APIs | 17 <dd> These are the same core JavaScript and DOM APIs |
18 that you can use in ordinary web apps. | 18 that you can use in ordinary web apps. |
19 <span class="comment">[PENDING: check! should link to complete list]</span> | 19 <span class="comment">[PENDING: check! should link to complete list]</span> |
20 <!-- Use onclick in your toolbar div to add click behavior. | 20 <!-- Use onclick in your toolbar div to add click behavior. |
21 E.g. window.open(someUrl). --></dd> | 21 E.g. window.open(someUrl). --></dd> |
22 <dt><strong> XMLHttpRequest </strong></dt> | 22 <dt><strong> XMLHttpRequest </strong></dt> |
23 <dd> | 23 <dd> |
24 Use <a href="xhr.html">XMLHttpRequest</a> | 24 Use <a href="xhr.html">XMLHttpRequest</a> |
25 to request data from one or more servers. | 25 to request data from one or more servers. |
26 The <a href="manifest.html#permissions">permissions</a> field | 26 The <a href="manifest.html#permissions">permissions</a> field |
27 of the manifest specifies | 27 of the manifest specifies |
28 which hosts the extension can send requests to. | 28 which hosts the extension can send requests to. |
29 </dd> | 29 </dd> |
30 <dt><strong> WebKit APIs </strong></dt> | 30 <dt><strong> WebKit APIs </strong></dt> |
31 <dd> | 31 <dd> |
32 Because Google Chrome is built upon WebKit, | 32 Because Google Chrome is built upon WebKit, |
33 your extensions can use WebKit APIs. | 33 your extensions can use WebKit APIs. |
34 Especially useful are the experimental CSS features | 34 Especially useful are the experimental CSS features |
35 such as filters, animations, and transformations. | 35 such as filters, animations, and transformations. |
36 Here's an example of using WebKit styles | 36 Here's an example of using WebKit styles |
37 to make the UI spin: | 37 to make the UI spin: |
(...skipping 16 matching lines...) Expand all Loading... |
54 localStorage.setItem("foo", "bar"); ... localStorage.getItem
("foo"); --> <span class="comment">[PENDING: Other important API? link
to complete list]</span></dd> | 54 localStorage.setItem("foo", "bar"); ... localStorage.getItem
("foo"); --> <span class="comment">[PENDING: Other important API? link
to complete list]</span></dd> |
55 <dt><strong>APIs in bundled libraries</strong></dt> | 55 <dt><strong>APIs in bundled libraries</strong></dt> |
56 <dd> If you want to use a library that the browser doesn't provide | 56 <dd> If you want to use a library that the browser doesn't provide |
57 (for example, jQuery), | 57 (for example, jQuery), |
58 you can bundle that library's JavaScript files with your extension. | 58 you can bundle that library's JavaScript files with your extension. |
59 Bundled libraries work in extensions | 59 Bundled libraries work in extensions |
60 just as they would in any other web pages. | 60 just as they would in any other web pages. |
61 </dd> | 61 </dd> |
62 </dl> | 62 </dl> |
63 | 63 |
OLD | NEW |