Skip to content

Latest commit

 

History

History
47 lines (22 loc) · 1.36 KB

File metadata and controls

47 lines (22 loc) · 1.36 KB

EnvironmentList

Summary

The list of available environments. (Don't create your own instances - use Sketch.environments)

Instance Properties

NameReturn TypeDescription
lastEnvironment
Read-only
Returns the last environment
currentEnvironment
Read/Write
Returns the current environment
this[index]Environment
Read-only
Returns the environment at the given index
countnumber
Read-only
The number of available environments

Instance Methods

environmentList:ByName(name)

Gets an Environment by name

Returns: Environment (The environment, or nil if no environment has that name)

Parameters:

NameTypeDefaultDescription
namestringThe name of the environment to get

Example

env = Sketch.environments:ByName("Pistachio")