A Flex Package is a collection of Flex code used in projects to define component interfaces and connections. Packages provide the message and transform definitions used in project designs.
The following types of packages can be added to your projects:
- Packages provided by Tangram Pro (e.g.
- Packages provided by any teams that you are a member of
- Packages you create
There are two main uses of packages in projects:
|Provides message definitions for the connections in project designs.||You can add the ||Flex code in this package will include message type definitions and any data types they are composed of.|
|Provides transform definitions for connections between components that use different interface packages.||You can add the ||Flex code in this package will include transform definitions and any functions or data types they are composed of.|
One or more packages can be added to a project by going to Flex Packages, searching for a package, and clicking the + button.
This will add the latest release of the package and allow you to use its messages or transforms in your design.
The Flex Editor is available in projects so you can create packages, write code and create releases in the same area as your project design. You can also access it outside of projects by going to FlexLang in the top menu.
While inside a project, go to Flex Packages, click the Open Flex Editor button and then Package Manager. From here you can create a package, or fork an existing one. Once created, you can add it your project and use its master branch or a release.
To learn more about managing packages see Flex Package Management
The master branch is editable. Use master in a project if you want to design and update Flex code in tandem. Flex code changes on the master branch will automatically update the component interfaces in your project design.
The master branch can be selected by going to Flex Packages and clicking the dropdown beside the package.
To learn about the Flex language syntax see Flex Docs
Package releases are immutable and read-only. Use a release to prevent effects from future package updates. You can always create a new release and switch your project to use it as needed.
A specific release can be selected by going to Flex Packages and clicking the dropdown beside the package.
You'll be asked to confirm and shown which messages are changing between releases. This will update the component interfaces in your design to the selected release.
Packages can be removed from projects by going to Flex Packages and clicking the x beside it.
You'll be asked to confirm, and shown the messages that are currently in use in your project design.