Syntax Error on autogenerated js minification file

I have been successfully using the React CMS Boilerplate to upload a custom React Module in Hubspot. Recently, I went to do some updates on the module and I’m getting this error

Uncaught SyntaxError: Invalid or unexpected token

in the minified main.js file (this file is autogenerated and I can not edit it). The error appears to be on the very last line of the minified file which is

`\#sourceURL=https://f.hubspotusercontent00.net/hubfs/{myHubspotID}/raw_assets/public/{myHubspotFolder}/main.js``

I have not experienced this error ever before so I’m wondering if something changed with how Hubspot builds the minified files? I did control tests and use the exact same code that worked previously and saw the same error today. Also I will note that the uploading process has no errors. I’m only seeing the error when I drag my module onto our page. That is where it crashes.

Hi @SaraRandolph

Welcome to the Community and thank you for the information provided!

I’ll tag a few of our wizards that can share their knowledge with you :slightly_smiling_face:

Hey @Kevin-C @Gonzalo @DanielSanchez any advice you can give to @SaraRandolph?

Thanks

Sharon

Hey @SaraRandolph

A shot in the dark here, but…

I believe a sourceURL is supposed to be designated with two forward slashes rather than two back slashes.

This would account for the

Uncaught SyntaxError: invalid escape sequence error

thrown in FF.

But because that’s causing an error with the source mapping I’m not sure I can tell where this is happening. If this is in fact the issue.

EDIT:

If you can get into that fileafter the production build and remove that line all together it might work.

Thank you Kevin! I ended up chatting with a developer on the Hubspot slack asking how I could update that file and he pushed up a fix for the issue!