FCF 2.0 development in progress...
> > > >
[News] [Packages API] [Downloads] [Donate to the project] [Contacts]

fcf.module() function

mixed fcf.module({name, dependencies, lazy, module} a_options)

Package: fcf-framework-core

File: fcf-framework-core:fcf.js

Available from version: 2.0.2

Declares an FCF module.

For more information on loading and declaring modules, see "Modules" page

Arguments

{name, dependencies, lazy, module} a_options
- An object containing module description options:
  • string name - Path (name) of the module in FCF notation

  • [string] dependencies - An array of module dependencies that will be loaded and passed to the module function as arguments.

  • [string] lazy - An array of module dependencies that will be loaded after the module function is executed. Dependency data can be used in case of cyclic dependencies and data is accessed via global variables.

  • function module - A function that should return module data. Arguments from the array of module dependencies act as parameters.

Result
mixed
- Result of module function execution