Open boy12371 opened 6 years ago
I'm not familiar with Cocos Creator, I never heard it before this issue!
After doing some research I think the problem is you need to import the nano-sql bundle instead of the nodejs module.
So you should use the single file bundle here: https://raw.githubusercontent.com/ClickSimply/Nano-SQL/master/dist/nano-sql.min.js instead of importing it using require
statements.
It still didn't work.
I'm not familiar with Coco's creator at all, hopefully someone with more experience can hop in here and help out.
Otherwise I'm not sure what's causing this bug and I won't have several hours to learn Cocos creator and dig into this for quite a while.
I tried to use it in cocos but it didn't work. It shows: ERROR: TypeError: undefined is not a constructor (evaluating 'new index_1.NanoSQLDefaultBackend()'), location: __node_modules/nano-sql/lib/index.js:65:49