什么是“Javascript引导加载程序”? [英] What is a "Javascript Bootloader"?

查看:181
本文介绍了什么是“Javascript引导加载程序”?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经看到这个主要是在Facebook的来源。 Bootloader.setResourceMap({bMxb7:{name:.... 什么是一个引导加载程序javascript?它的用途和目的是什么?

I have seen this mainly in the source of Facebook Bootloader.setResourceMap({"bMxb7":{"name":.... What is exactly a bootloader in javascript? What is its use and purpose?

推荐答案

一般来说,引导程序是一个(相对较少的)代码,建立所有后续代码需要运行的环境,因此它也是第一个要执行的代码,通常仅限于操作系统,但对FB也是有意义的。

Generally speaking, the bootloader is a (relatively) small amount of code responsible for establishing the environment that all subsequent code requires to run, as such it is also the the first code to be executed. It's usually restricted to OSes, but makes sense for FB too.

在Facebook的情况下,引导加载程序将执行诸如加载附加的JS文件和库所需的其他资源,除了单个公开的< script /> 开发人员包含在文件中。

In the case of Facebook, the bootloader will do things like loading additional JS files and other resources that the library needs in addition to the single public <script /> the developer included in the document.

这篇关于什么是“Javascript引导加载程序”?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆