Repository navigation
Domo.js Library
Table of Contents
The domo.js library provides a set of common tools to assist in building a Domo App Design.
Some meta-data specific to Domo is passed into the card as query parameters in the iframe.
<iframe src="//85992d26-6d77-4c99-95e2-7284ecbbdcb0.domoapps.prod2.domo.com?userId=2133179061&customer=dev&locale=en-US&environment=dev3&platform=desktop&size=large">The domo.js library parses and exposes these in the domo.env object.
An id unique to the user that is viewing the card.
domo.env.userId // Example: 2133179061
The name of the customer on which the app has been installed.
domo.env.customer // Example: dev
The locale set on the customer that the app is installed with.
domo.env.locale // Example: en-US
The environment that the app is running on. This may be useful for hiding features that are not ready for production yet.
domo.env.environment // Example: dev3
The platform that the user is using to view the app. Currently only desktop is supported, but there are plans for mobile to be implemented as well.
domo.env.platform // Example: desktop
The size of the card that is used to display the app. Although a Design can specify its default sizing, the user can always override that sizing to make the app smaller or larger.
domo.env.size // Example: large