hiukim / mind-ar-js

Web Augmented Reality. Image Tracking, Face Tracking. Tensorflow.js
MIT License
2.22k stars 414 forks source link

Minimal Example of face tracking does not work #367

Closed kageori closed 1 year ago

kageori commented 1 year ago

Hi,

When I try to run the minimal face tracking example code on local server, I get an error Uncaught SyntaxError: Illegal return statement (at mindar-face-aframe.prod.js:1:1648) as shown in the attachment.

I am using the following code as is. https://hiukim.github.io/mind-ar-js-doc/face-tracking-quick-start/webpage

How should I deal with this?

スクリーンショット 2023-03-18 13 21 32
hiukim commented 1 year ago

Thanks for reporting. You will need to add type=module. I'll fix the documentation.

<script src="https://cdn.jsdelivr.net/npm/mind-ar@1.2.1/dist/mindar-face-aframe.prod.js" type="module"></script>

kageori commented 1 year ago

Thank you.

I tried to change it, but there appears to be another error.

スクリーンショット 2023-06-03 16 02 34
hiukim commented 1 year ago

what other error

kageori commented 1 year ago

As you can see in the attached screenshot above. Uncaught SyntaxError: Illegal return statement (cdn.jsdelivr.net/npm…ce-aframe.prod.js:1)

hiukim commented 1 year ago

sorry, my bad. Ignore my previous comment.

But it should now be fixed in latest version v1.2.2

kageori commented 1 year ago

It worked!

Thank you so much!