You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
SOLUTION:
Use one of the following approaches to fix build issue you are experiencing:
Dynamically download the Deep Chat module via a script instead of a project dependency which will prevent Deep Chat from being evaluated during build time. Configure your framework of choice to append the following <script> tag to the <head> element: <script type="module" src="https://unpkg.com/deep-chat@1.1.20/dist/deepChat.bundle.js" ></script>
Please note that scripts can take time to download, so if you are seeing problems with your properties not being applied in time, we advise you to attach an onload listener to the <script> tag so you can conditionally render the <deep-chat> code when it loads. You can achieve this by; giving the <script> an id, searching for it using document.getElementById and then adding onload to the result element. Check a live example for this in Vue 2.
Older build tools/loaders/transpilers have problems using newer JavaScript syntax, one way to overcome the problem is by simply upgrading them.
If you are experiencing other problems or have your own solutions, do not hesitate to comment below or create a new issue.
OvidijusParsiunas
changed the title
Workaround for building a project that uses ES5/ES2015 JavaScript
Workaround for build errors when using Deep Chat
Aug 31, 2023
After importing Deep Chat - some projects that target older versions of JavaScript or use specific configurations can encounter new build errors.
The text was updated successfully, but these errors were encountered: