Error: Unexpected export statement in CJS module. Cocos Creator 3.7.0

HI all, I installed uuid package, uuid - npm, but I can’t import it, see this error:
Error: Unexpected export statement in CJS module.

Hi, To use the uuid npm package you need to:

  1. install the npm package npm install uuid
  2. In the uuid directory of node_module, find package.json and add type, e.g. “type”: “module”
  3. Close the Creator editor, delete the cache folder, library and temp folders under the project and restart the Creator editor

DEMO:
NewProject.zip (97.1 KB)

Thanks, works, but really to say looks complicated a little bit… I remember I could use mode_modules in previous versions… without changing anything.

That is not good?
if my code is in the github, pull code by ohter user, Then they ‘npm install’. they don’t know this operation.
will there be problems?

Is this follow -up plan?

I also got this error trying to import this library polygon-clipping - npm