# Module selenium-webdriver/_base

code »

The base module responsible for bootstrapping the Closure library and providing a means of loading Closure-based modules.

Each script loaded by this module will be granted access to this module's `require` function; all required non-native modules must be specified relative to this module.

This module will load all scripts from the "lib" subdirectory, unless the SELENIUM_DEV_MODE environment variable has been set to 1, in which case all scripts will be loaded from the Selenium client containing this script.

Show:PublicProtectedPrivate

## Functions

code » exportPublicApi ( symbol ) ⇒ `!Object`

Loads a symbol by name from the protected Closure context and exports its public API to the provided object. This function relies on Closure code conventions to define the public API of an object as those properties whose name does not end with "_".

Parameters

symbol: `string`
  The symbol to load. This must resolve to an object.

Returns

An object with the exported API.

Throws

`Error`
  If the symbol has not been defined or does not resolve to an object.

code » isDevMode ( ) ⇒ `boolean`

Returns

Whether this script was loaded in dev mode.

code » require ( symbol )

Loads a symbol by name from the protected Closure context.

Parameters

symbol: `string`
  The symbol to load.

Returns

The loaded symbol, or `null` if not found.

Throws

`Error`
  If the symbol has not been defined.

## Properties

code » closure : `Object`