šŸ“…[New Plugin] Air Calendar (FullCalendar)

A different error message today

The plugin Air Calendar (Full Calendar) / element AirCalendar threw the following error: TypeError: b.data.fn_initializeCalendar is not a function
at eval (eval at m.create_code (https://dhtiece9044ep.cloudfront.net/package/run_debug_js/866d8ce16ee537c487a5e48ba6659da0ae11f02c052c636a0965959e34598ea2/xfalse/x5:15:1898423), :17:65)
at https://dhtiece9044ep.cloudfront.net/package/run_debug_js/866d8ce16ee537c487a5e48ba6659da0ae11f02c052c636a0965959e34598ea2/xfalse/x5:15:1921563 (please report this to the plugin author)

I guess @Bubble havenā€™t fixed all the plugin bugs yet?

Simon

@simon We are reviewing your bug report to determine if this is a bug on our end or with the plugin.

1 Like

great thanks

Hi any update on this @neerja ?

Thanks
Simon

1 Like

Adding my name to the hat for this problem

Some added info: This problem also appears to occur when the ā€œDate/Time Range Selectorā€ element is added to the screen.

@willtaylordesign good to have a fellow sufferer. I have had a support ticket open for 3-weeks now on this.

Simon

1 Like

@willtaylordesign I just took a look at the ā€œDate/Time Range selectorā€ and realized it uses the moment.js library which Air Calendar also uses. Just maybe this might have something to do with it because iā€™ve also had some reports from those using the Air Calendar and Air Date/time picker (which also uses moment.js).

@neerja could this be the problem? If two plugins are loading different versions of a javascript library (e.g. moment.js in this case) what will happen.

@neerja on a more general case @Bubble should really listen to us and include commonly used libraries like moment.js so that different plugins doesnā€™t have to load different versions of the same library. On top of my head i know about 8 to 10 different plugins using moment.js. An option in the plugin editor that allows you to include a library like the way currently we can check a box to include jquery.
I donā€™t want to rely on another plugin loading a library for my plugin as that may also lead to some issues (e.g incompatible versions or something broken in their version of the library).

@seanhoots Our engineering team aims to have an update for this issue within the week. Iā€™ve also shared your feature request for commonly used libraries in the plugin editor.

3 Likes

@seanhoots that sounds very plausible to me because if I remove one of the plugins from you it starts working.

I wonder if the quickest bodge fix it to get your two plugins on the same version of moment.js?

Simon

@simon iā€™m not entirely sure if this is the problem. My Air Calendar demo uses has both plugins and it still works. So there might be another reason.
Lets see what Bubble engineers comes up with.

Iā€™m having an issue with the calendar not showing up. I gave up using it in a reusable for this very reason and just built my scheduler direct into the page. That worked fine until I tried to copy & paste with workflows today.

On the page I copied it to, Iā€™m getting these errors now.

I was reading up above and deleted the Air Date/time picker plugin from the app and now the calendars are working. Including the reusable I had given up on lol. I wasnā€™t actually using the Air Date/time picker element on any of the pages, just had it installed in the app.

@seanhoots Have you heard back from Bubble?

So far, It does look like all three (below) known plugins interfering with Air Calendar are utilizing the moment.js library. I think your demo might be using a beta version for testing future features? Since that version looks not to be affected, would that mean releasing a version of it (minus the in progress portions) would fix it? (Iā€™m happy to be a guinea pig! :slight_smile: )

Also, every now and then I get the calendar working just by moving the Timex plugin element into a different group/location/layer on the same page. (itā€™s very random and I havenā€™t noticed a pattern, other than confirming when it does work that moving it is the only change I made). As a workaround, is there maybe a way to delay loading (not delay displaying) plugins running on a page so that their code runs in a specific order?

@willtaylordesign no I havenā€™t heard anything on this from Bubble.

Also my demo version uses the same moment.js library version as the published one.

But as you discovered yourself that moving around the plugin elements sometimes make it work this might be the reason why my demo version doesnā€™t have any issues.
Itā€™s obvious now that this issue is being caused by different versions of moment.js library being loaded.
So I think itā€™s a matter of which version loads first and this depends on which element loads first.
The moment library adds the moment instance to the global space and that is what the calendar plugin uses. So if the other plugins load first their moment version the calendar picks that up leading to the issue i think.

The best way to address this issue as iā€™ve mentioned to bubble several times is to include an option for plugins to specify that it uses the momemt.js libary (similar to how they allow us to check a box to include jquery).
This way plugin developers can ensure their plugin works with whatever moment.js libary bubble has.
Iā€™ve counted more than 10 plugins all using moment.js libray with a number of them using different versions of the library.
Aside this compatibility issue this also even causes delay in load times if each plugin loads its own library which by the way is a huge library.

@Bubble @neerja Any updates on this?

Thanks

Simon

2 Likes

Hi Sean
I am facing a peculiar problem with the plugin - seems to work fine in dev. But in production it disappears sometimes & says missing element (happening more regularly now). I am subscribed to the plugin and paying as well. Dont have the Air Calendar plugin there either (which caused a conflict earlier). Please help resolve this - i can probably get it to work by deleting and rebuilding it, But thats a tedious producess and I did that once before

@kunalsingh2705 if itā€™s working in development but not in live I think you should file a bug report to Bubble as it may be a bubble thing.

@bubble @neerja @seanhoots

Just refreshing this inquiry from a week ago. Has there been any an update? Could a workaround be to arrange elements in a way that the order their libraries are loaded in can be controlled? If so, how would we go about that in the editor?