Plugin devs - Minify blues

For developers using the Construct 2 Javascript SDK

Post » Sun Sep 24, 2017 7:23 pm

I can't submit this as a bug report because it's to do with the SDK and the closure compiler minfier. So, to all you javascript devs, just be aware that if you use the array.includes(x) method then it will become corrupted by the minifier (r246). Of course, you can work around using array["includes"](x).

Just for info in case anyone else gets caught out by this (that's an hour of my life I shalln't get back)! :)
Learning other engines, but C2 still rocks. Image Image Image Image
B
81
S
22
G
96
Posts: 2,467
Reputation: 58,351

Post » Fri May 11, 2018 3:01 am

just to add to this list:

Don't use cr.ObjectSet.s.forEach(foo) because the c2 closure compiler is not compatible...
Learning other engines, but C2 still rocks. Image Image Image Image
B
81
S
22
G
96
Posts: 2,467
Reputation: 58,351


Return to Javascript SDK

Who is online

Users browsing this forum: No registered users and 0 guests