Forum Documentation Showcase Pricing Learn more

[Plugin Update - Oct 9, 2019] 'Env' Environment Variables

Hello bubblers,

Pushed a couple of updates to the ‘Env’ Environment variable plugin:

  1. Define upto 6 Env variables with a single element :sunglasses:
  2. Trigger workflows when a variable data changes :fire:
  3. Improved architecture enhancing performance

The demo & documentation have also been updated.

Its’ backward compatible. So if you’ve previously purchased the plugin, simply update the version in your plugins tab.

Cheers,
Gaurav

3 Likes
  • Create any number of Env variables from any spot in the app
  • Read any variable from several places in the app simultaneously
  • Write to any variable from any place in the app (workflow, action, auto-binding)
  • Auto-bind any variable from one / several places in the app
  • Trigger workflows when the Env’s value changes from any source
  • Read / write any variable through JavaScript code
  1. Fast : They don’t touch the database or any external service.
  2. Temporary : Exist only until page exists. Destroy on reload / page change. Can be saved to database fields via workflows when required
  3. Flexible : Can be used with code as well as bubble. Dramatically reduces workflows. Truly connects reusable elements with each other & app pages

Hassle-free setup without any need for database, workflows or custom states

Run a JavaScript code, and map a variable in your code to an Env variable

Screen recordings showing how the demos were built:

Setup video 1 - Sharing & syncing data across reusables and triggering workflows:

Setup video 2 - Run a JavaScript code, and mapping the output to an Env variable:

1 Like

Awesome @gaurav!

One of my most-used plugins.

2 Likes

By the way, one challenge with the plugin (which is not a bug, but a general Bubble issue as far as I know), is that if the Env. Variable element is hidden when the variable is set, it will not receive the data until you “rewrite” the variable content again. This is especially a challenge with reusables, that are often invisible by default until they’re needed. It can easily be solved with workflows of course, but I’m curious if there are other ways this could be solved.

Something like a checkbox “Automatically fetch value when element becomes visible” or something. Is that something that could be implemented? Or do you know of an easy fix that I’m overlooking?

This version fixes that :slight_smile:

The only thing is that an Env needs to visible once for the code to load (that’s a bubble restriction).

Also you don’t actually need an Env element to set the variable. There’s a workflow step ‘Set Env’ which allows you to do this without any element.

1 Like

Perfect :slight_smile:

Also you don’t actually need an Env element to set the variable. There’s a workflow step ‘Set Env’ which allows you to do this without any element.

Ah, I thought the workflow needed the Element to work. Thanks for the tip :slight_smile:

Element actions need element to be visible. Workflows don’t. The Env variables supports both formats

1 Like

Tested working, thanks!

@gaurav would be possible for you to add the ability to conditionally check ‘update value’

image

Done. Just pushed an update changing the checkbox to dynamic yes / no

2 Likes

I’ll be buying this tonight, been meaning to for a while

1 Like

Thanks!!!

You, my friend, are a BUBBLE HERO! This is awesome! Pair this with an If-Then-WF and you can do just about anything :astonished:

I’ll be updating my plugin today!

I did not know this. For clarification, if I use an Env called activejob in one reusable, I can set the value of that Env from a second reusable without adding an Env on the second reusable?

2 Likes

Haha thanks @eli :smiley:

Oh yes absolutely… reusable, repeating group, main page etc. anywhere you can run a workflow from, you can set the value of an env. The element is required only to create & read the value of an env :slight_smile:

1 Like

Rockstar!

1 Like

Page by page my app is changing from this:

image

To this:

image

The ability to store 6 variables in one Env is so much cleaner and more manageable.

3 Likes

There’s a nifty little preview feature as well there :slight_smile: If you want to quickly see the variable names you’ve defined in the element just increase the size and it’ll list those as preview

2 Likes

You my good man are just on a charm offensive today :joy:

2 Likes

Hi @gaurav, is it possible to read a variable from a different page in the app?