Error ‘$jscomp is not defined’ When Publishing Plugin

Now you can build your own Rich Text Editor using native Bubble Actions - https://xl-rich-text-editor.bubbleapps.io/

Plugin is here - https://bubble.io/plugin/rich-text-editor-xl-1549672193452x248975639913693200

Please let me know your thoughts.

11 Likes

It work fine. Great.

1 Like

Hmm, at first review this seems pretty genius.

1 Like

Part 1
com-video-to-gif-2

Par 2
com-video-to-gif-3

Part 3
com-video-to-gif-4

Dear Fellow Plugin Developers!

A lesson learn here:

When I originally published the plugin, I had a Demo page running plugin (like a test version) and the “live version” out there. Later a couple of subscribers contacted me saying that the plugin in did not work at all.

Basically, although the plugin in worked well in test mode it for some reason did not publish well.

The error was to do with ‘$jscomp is not defined’, which is to do with compiler…

The solution was a follows:

While in plugin editor:

  1. Open browser Console;
  2. In Console, type and run ‘window.do_not_minify_plugin = true’;
  3. Publish the plugin

This worked for me. Hope will help you too.

4 Likes

I would like to buy you a beer Sir. This plugin might just change my life.

2 Likes

If this plugin could expose an “Insert text” / “Insert HTML” action, it’d be gold. Is that on the cards?

2 Likes

Insert Delta and Plain Text should already be there as actions.

Insert HTML is added and is NOW added too.

Anything else on your wish list?

2 Likes

Jeepers, that was fast! Thanks so much. I’ve subscribed to the plugin now, I’ll let you know if anything else comes up. Thanks again!

1 Like

Is there a way to insert the HTML / plain text at the cursor?

Also, I use a lot of <video> and <table> tags in my app, but when I use the “Replace HTML” action with a video player or a table it doesn’t show the player or the table inside the text editor :cry:. I’ve put a couple of examples of the code I’m trying to insert below (the table is just lifted from w3schools.com it’s not real data of mine):

<video width="320" height="240" controls>
<source src="http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4" type="video/mp4">
Your browser does not support the video tag.
</video>

<table>
  <tr>
    <th>Company</th>
  </tr>
  <tr>
    <td>Alfreds Futterkiste</td>
  </tr>
  <tr>
    <td>Centro comercial Moctezuma</td>
  </tr>
  <tr>
    <td>Ernst Handel</td>
  </tr>
  <tr>
    <td>Island Trading</td>
  </tr>
  <tr>
    <td>Laughing Bacchus Winecellars</td>
  </tr>
  <tr>
    <td>Magazzini Alimentari Riuniti</td>
  </tr>
</table>
1 Like

The Insert at cursor action is ADDED.

Today I fixed Video for YouTube and Vimeo.

Your video would work too (please see below, you need to insert //commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4 [no http])
(I shall fix this to me automatic too…)

In terms of tables, it is on the list but my current solution is not good for publishing…
Tables are at priority as I need them myself.

2 Likes

That’s all great news, thanks so much!

The Insert at cursor action is added.

You may insert Plain Text as well as HTML.

Example are at the bottom here - https://xl-rich-text-editor.bubbleapps.io/

Could you please update your plugin and let me know if that is what you expected?

Hey!
Will you be pulling the price down anytime soon? I’m doing a school project and I’m considering it, but a $150 is probably a little too much for me. (I feel like a total CB)

It’s perfect, works exactly as I imagined, thanks so much!

Unfortunately the insert video action puts the mp4 url into an iframe, so I can’t switch off autoplay. I’m often displaying multiple videos on the screen at once so it won’t work without the <video> tag.

@ikkyu1755 this plugin is definitely worth the money, why don’t you try the monthly subscription first?

1 Like

Could you DM me an example of what you are trying to achieve in terms of having multiple videos?

I will look into the video tags and see if these may be used instead of iframes :slight_smile:

I’m going to do a monthly subscription, I’ve decided.
Sorry for asking, I was thinking weirdly, lol.
I’ll post a review of it later when I get the plugin. Thanks for making good stuff like this!

@funwtp On the demo page, the subscript demo is written as “superscript”. Maybe edit that also!

1 Like

This helpful comment is the only reason why price has not gone up [yet].

Was this ever reported to Bubble as a bug (paging @neerja :slight_smile: )? I see a similar problem in a plugin that I am building.

I have a function defined as async (like " node.onclick = async function datePick(){ ") which works fine in my testing app, but does not work in apps that I’ve given Private access to.

One key difference (as you note) between testing mode and published mode is minification / compilation. When run in published mode, my plugin throws:

Uncaught ReferenceError: $jscomp is not defined
    at HTMLDivElement.d.onclick (eval at b.create_code (x5:17), <anonymous>:19:179)

Of course, in production mode I want my plugin to be minified, etc.

The problem area per the error message is:

d.onclick=function(){var b=this,e,d,f,g,h,k,l,p,n;return $jscomp.asyncExecutePromiseGeneratorProgram(function(c){if(1==c.nextAddress){e=b.date;console.log("We are in datePick: clickDate is...",e,b.value,typeof b.value,e,typeof e);if(b.disabled||!a.data.moderange||a.data.picking)return c.jumpTo(2);console.log("WE ARE IN RANGEPICK START"); … etc.

So it looks like this compile/minify error (in my case) has something to do with the async nature of the function. (And this function must be called as async as it does some Promise handling and awaits resolution of a Promise within it.)

(And, after testing your solution @funwtp, I find that the published plugin does work. I don’t like that it’s in non-minified mode, however!)

1 Like