Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migrated to Confluence 5.3

...

Section
Column
width65%

In Fluid, a unit is a bundle of data and functions representing a "type" or "class" of object in JavaScript. Units are defined using plain old objects and functions. JavaScript has a very loose, dynamic type system where objects can be modified and augmented freely at run time. The language doesn't have the concept of classes, and many familiar attempts to impose a classical system on the language have proved awkward and unworkable. Units address this by embracing a simple and functional approach to packaging up objects.

Column
solid
Panel
borderStyle
borderColor#566b30
bgColor#fff
titleBGColor#D3E3C4
borderStylesolid
titleOn this Page
Table of Contents
toc
maxLevel
5
minLevel2maxLevel5
excludeIntroduction*

In idiomatic JavaScript, inheritance is prototypal. An object can inherit from another object simply by creating a new instance and modifying its functionality. No classes, no static types. Used carefully, this is a good thing.

...