MDN’s new design is in Beta! A sneak peek:

Enabling Experimental Jetpack Features

The proposed method for accessing Jetpack features that are still in development and may be added in the future is inspired by python's future module. In Python, you can call

from __future__ import foo

which adds the functionality that foo yields to the script. In Jetpack, we propse adding a new function to the base namespace called importFromFuture.


import(stringMountPath string)Imports the requested experimental feature into the script.
stringMountPathString that enumerates where, starting from the jetpack base, the feature will be mounted. To get a list of mount paths that are available, see the method below. string

Here is an example of how to import a feature (the clipboard) from the future.


The goal here is to be able to remove the jetpack.future.import() call when the feature has been formally accepted into the core without additionally changing the script (barring any other changes made during integration).

list() arrayReturns an array of the set of potential stringMountPath as used in jetpack.future.import().

This is an example of how to get this array. A quick way of displaying the list is to write it to the console.log.

var list = jetpack.future.list();

Open the firebug console to view.

Document Tags and Contributors

 Contributors to this page: Sheppy, JetpackBot
 Last updated by: Sheppy,