Library
Library of functions to load remote libraries of code.
Functions
Load
Loads a library.
Syntax:
Library.Load(url: string)
Parameters
url
: The publicly-accessible URL where the library is hosted.
Example:
// Assume a library exists at http://example.org/code.snapi with the following content:
// a(v: int) = v * 2
// b() = 1
//
// This library can then be used as:
let MyLib = Library.Load("http://example.org/code.snapi"),
v1 = MyLib.a(2),
v2 = MyLib.b()
in
v1 + v2 // Evaluates to 5