playcanvas / editor

Issue tracker for the PlayCanvas Editor
https://playcanvas.com/
160 stars 28 forks source link

Code Editor: console error when working with mjs scripts #1190

Closed LeXXik closed 2 months ago

LeXXik commented 2 months ago

Code Editor shows a console error when working with .mjs scripts. The scripts do no have attributes and do not use Script class.

image

And also possibly related:

image

marklundin commented 2 months ago

Thanks for the report. Is this in a blank project?

On Fri, 23 Aug 2024 at 15:09, Will Eastcott @.***> wrote:

Assigned #1190 https://github.com/playcanvas/editor/issues/1190 to @marklundin https://github.com/marklundin.

— Reply to this email directly, view it on GitHub https://github.com/playcanvas/editor/issues/1190#event-13992391121, or unsubscribe https://github.com/notifications/unsubscribe-auth/AADJFLF22KRHEDY7J4NUQ4LZS4RAJAVCNFSM6AAAAABNAA2Z52VHI2DSMVQWIX3LMV45UABCJFZXG5LFIV3GK3TUJZXXI2LGNFRWC5DJN5XDWMJTHE4TEMZZGEYTEMI . You are receiving this because you were assigned.Message ID: @.***>

LeXXik commented 2 months ago

The second screenshot appears in a blank project, which has an .mjs file with simple contents:

// my-class.mjs
class MyClass {}

The first one seems to need some other conditions.