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
{{ message }}
This repository has been archived by the owner on Apr 21, 2021. It is now read-only.
When compiling an angular app that uses terser for production use the following error occurs compiling ThreeBox code:
Error: main.1a5fcd07c173571f6663.js from Terser Unexpected token: name (static) [main.1a5fcd07c173571f6663.js:5215,28] at js_error (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:538:11) at croak (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1251:9) at token_error (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1259:9) at unexpected (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1265:9) at Object.add_parameter (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1736:33) at binding_element (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1993:29) at parameter (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1800:17) at parameters (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1774:25) at _function_body (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:2047:19) at function_ (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1698:20)
Although I do not know terser's behavior the error is simply resolved by changing the variable 'static' name to another (non-reserved token) name.
The referred variable is located in src/objects/objects.js in the addMethods function.
The text was updated successfully, but these errors were encountered:
AlexMViver
changed the title
Compatibility Error with Terser
Compatibility Error with Terser (and the simple fix)
Dec 5, 2020
Hi @AlexMViver
Just FYI, since a year ago I’m maintaining a new fork from Threebox with many new features (that is also in production) such as the following:
When compiling an angular app that uses terser for production use the following error occurs compiling ThreeBox code:
Error: main.1a5fcd07c173571f6663.js from Terser Unexpected token: name (static) [main.1a5fcd07c173571f6663.js:5215,28] at js_error (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:538:11) at croak (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1251:9) at token_error (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1259:9) at unexpected (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1265:9) at Object.add_parameter (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1736:33) at binding_element (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1993:29) at parameter (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1800:17) at parameters (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1774:25) at _function_body (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:2047:19) at function_ (C:\Users\Alex\Documents\Lapr5\SPA\node_modules\terser\dist\bundle.min.js:1698:20)
Although I do not know terser's behavior the error is simply resolved by changing the variable 'static' name to another (non-reserved token) name.
The referred variable is located in src/objects/objects.js in the addMethods function.
The text was updated successfully, but these errors were encountered: