Mr. Panda
Tech For Fun

[JavaScript] JavaScript 保留字和 H5 API

web api 是在开发 web app 时有力的工具,下面展示了 html5 中的 web api,详细的用法可以参考 MDN web api 文档,后期会出一篇 web api 用法和兼容性的系列文章,通过一些小 demo 打开 web api 开发的大门,为我们的 web 应用增添更多的功能支持。

JavaScript Reserved Words

abstractfinalpublic
booleanfinallyreturn
breakfloatshort
byteforstatic
casefunctionsuper
catchgotoswitch
charifsynchronized
classimplementsthis
constimportthrow
continueinthrows
debuggerinstanceoftransient
defaultinttrue
deleteinterfacetry
dolongtypeof
doublenativevar
elsenewvoid
enumnullvolatile
exportpackagewhile
extendsprivatewith
falseprotected

List of HTML5 APIs for Coding with JavaScript

API What It Does
Ambient Light API Provides information about the ambient light levels, as
detected by a device’s light sensor.
Battery Status API Provides information about the battery status of the
device.
Canvas 2D Context Allows drawing and manipulation of graphics in a browser.
Clipboard API Provides access to the operating system’s copy, cut, and
paste functionality.
Contacts Allows access to a user’s contacts repository in the web
browser.
Drag and Drop Supports dragging and dropping items within and between browser
windows.
File API Provides programs with secure access to the device’s file
system.
Forms Gives programs access to the new data types defined in
HTML5.
Fullscreen API Controls the use of the user’s full screen for web pages,
without the browser user interface.
Gamepad API Supports input from USB gamepad controllers.
Geolocation Provides web applications with access to geographical location
data about the user’s device.
getUserMedia/Stream API Provides access to external device data (such as webcam
video).
History API Allows programs to manipulate the browser history.
HTML Microdata Provides a way to annotate content with computer-readable
labels.
Indexed database Creates a simple client-side database system in the web
browser.
Internationalization API Provides access to locale-sensitive formatting and string
comparison.
Offline apps Allows programmers to make web apps available in offline
mode.
Proximity API Provides information about the distance between a device and an
object.
Screen Orientation Reads the screen orientation state (portrait or landscape) and
gives programmers the ability to know when it changes and to lock
it in place.
Selection Supports selecting elements in JavaScript using CSS-style
selectors.
Server-sent events Allows the server to push data to the browser without the
browser needing to request it.
User Timing API Gives programmers access to high-precision timestamps to
measure the performance of applications.
Vibration API Allows access to the vibration functionality of the
device.
Web Audio API API for processing and synthesizing audio.
Web Messaging Allows browser windows to communicate with each other across
different origins.
Web Speech API Provides speech input and text-to-speech output features.
Web storage Allows the storage of key-value pairs in the browser.
Web sockets Opens an interactive communication session between the browser
and server.
Web Workers Allows JavaScript to execute scripts in the background.
XMLHttpRequest2 Improves XMLHttpRequest to eliminate
the need to work around the same-origin policy errors and to make
XMLHttpRequest work with new features of
HTML5.

参考:MDN:Web APIs

Jonsam

一个理科IT宅男,喜欢旅游、分享和美食,做点想做的事情,遇见想见的人。

🍒 美食 | 🌐 FE | 🕌 旅行 | 💻 加班 | ♍ 处女座

jonsam ng

jonsam ng

文章作者

海阔凭鱼跃,天高任鸟飞。

[JavaScript] JavaScript 保留字和 H5 API
web api 是在开发 web app 时有力的工具,下面展示了 html5 中的 web api,详细的用法可以参考 MDN web api 文档,后期会出一篇 web api 用法和兼容性的系列文章,通过一些小 demo 打开 w…
扫描二维码继续阅读
2021-09-05