官术网_书友最值得收藏!

How do we work with JavaScript?

All this is quite well, but as we mentioned before, it so happens that the JS version available most everywhere isn't ES8, but rather the earlier JS5. An exception to this is Node.js: it is based on Chrome's V8 high-performance JS engine, which already has several ES8 features available. Nonetheless, as of today, ES8 coverage isn't 100% complete, and there are features that you will miss. (Check out https://nodejs.org/en/docs/es6/ for more on Node and V8.)

So, what can you do, if you want to code using the latest version, but the available one is an earlier, poorer one? Or, what happens if most of your users may be using older browsers, which don't support the fancy features you're keen on using? Let's see some solutions for that.

If you want to be sure before using any given new feature, check out the compatibility table at https://kangax.github.io/compat-table/es6/. (See Figure 1.1). For Node.js specifically, check out http://node.green/.

Figure 1.1. - The latest versions of JS aren't yet widely and fully supported, so you'll have to check before using any of their new features

主站蜘蛛池模板: 汉源县| 会理县| 中卫市| 蓬莱市| 拜泉县| 福清市| 巨野县| 岢岚县| 观塘区| 湄潭县| 吉木乃县| 津南区| 称多县| 华坪县| 赣州市| 嘉义市| 福清市| 璧山县| 怀仁县| 崇左市| 南丰县| 原平市| 依安县| 龙口市| 鄄城县| 梧州市| 宣化县| 南乐县| 龙川县| 中山市| 同德县| 普兰店市| 花垣县| 广饶县| 南溪县| 扎囊县| 汉阴县| 嘉义县| 广州市| 泰顺县| 永泰县|