关键字
| break | do | instanceof | typeof |
| case | else | new | var |
| catch | finally | return | void |
| continue | for | switch | while |
| debugger | function | this | with |
| default | if | throw | delete |
| in | try |
ECMA-262 第三版保留字
| abstract | enum | int | short |
| boolean | export | interface | static |
| byte | extends | long | super |
| char | final | native | synchronized |
| class | float | package | throws |
| const | goto | private | transient |
| debugger | implements | protected | volatile |
| double | import | public |
还有在严格模式下的保留字,就不列出来了
不用熟记关键字,只需要知道平时在写js的时候用到的都是关键字,例如var if else function 等等,这样你就知道哪些是关键字了。
保留字是即将可能会用到的只需要稍微注意下,不要用平时写其它语言的关键字来做js的标识符就行了。