Modules/Secure

From CommonJS Spec Wiki
Jump to: navigation, search

To be usable in secured module loaders, a module must conform to additional constraints:

  1. A module must not write to any free variables or their transitive members.
  2. A module must not refer to any free variables apart from primordials ("Object", "Array", etc. as defined by ECMAScript), "require", "environment", and "exports".
  3. A module must not tamper with (assign to, assign to members of, delete, or otherwise mutate) the transitive primordials.
Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox