Discussions

Expand all | Collapse all

Alternative to Image on Load : inline javascript Support ended

  • 1.  Alternative to Image on Load : inline javascript Support ended

    Posted 08-23-2021 02:39
    I have used inline javascript in many places in my Apps. Since now the support for inline javascript is ending. Can someone please help with the alternatives to the features used. I have used image on Load at most places, Along with Image on Load error. 
    https://community.quickbase.com/blogs/graham-leto2/2021/02/03/upcoming-changes-to-javascript-in-quickbase

    ------------------------------
    Abhishek Choudhary
    ------------------------------


  • 2.  RE: Alternative to Image on Load : inline javascript Support ended

    Posted 08-23-2021 09:29
    Just to be clear the support for it is not ending. The support for adding NEW JavaScript is ending. Everything you have will continue to work as it does for now so there likely isn't a huge rush to change.

    Look into Service Workers. There are many older posts where people talked about them as a replacement. AFAIK there isn't an easy copy and paste solution here so it will take more work than setting up IOL for many people probably. Look up "service worker travel log" as well. I gave #3 below but there is 1 and 2 and more as well.

    https://community.quickbase.com/communities/community-home/digestviewer/viewthread?MessageKey=49e8f748-b9fe-4c80-9086-e42dd4e7bf58&CommunityKey=d860b0f8-6a48-487b-b346-44c47a19a804&tab=digestviewer

    https://community.quickbase.com/communities/community-home/digestviewer/viewthread?MessageKey=41c90412-94f6-4993-9b1d-3ba2ba1ae0e8&CommunityKey=d860b0f8-6a48-487b-b346-44c47a19a804&tab=digestviewer


  • 3.  RE: Alternative to Image on Load : inline javascript Support ended

    Posted 08-23-2021 10:56

    Hi Abhishek,

    As part of our 6 month program to encourage users to begin moving off of JavaScript and into native functions we did publish some helpful resources. Depending on the use case for your JavaScript (because it can be very flexible) there are a number of native functions that can help you. For example JavaScript is still supported in our code pages functionality and we have a Code Page Sample App that includes some examples of how to start using code pages to replace common JS functionality. 

    We have also been making changes to some of our features in product, like our formula syntax so support more options for redirects, popups and more. You can find a list of alternatives to common JS use cases in our Alternatives to common JavaScript Insertion techniques article.

    Austin is correct that there are some admins who have chosen to use Service Workers, I would give the same warning we have given in the past about JavaScript Insertion. It isn't a functionality we test for or support, so when we do our normal releases there is the chance that your service workers (like JS before it) can break. Since Service Workers can alter the data sent from QB via the browser of that user it also has security and reliability concerns we warn admins to think about before making use of them. It isn't something we recommend. 



    ------------------------------
    Evan Martinez
    ------------------------------