We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1c65b92 commit eb623d0Copy full SHA for eb623d0
README.md
@@ -31,11 +31,14 @@ const predictions = await model.detect(img)
31
## Usage via Script Tag
32
No npm install required. Just import via the script tag.
33
```html
34
-<script src="https://cdn.jsdelivr.net/npm/@cloud-annotation/object-detection"> </script>
+<script src="https://cdn.jsdelivr.net/npm/@cloud-annotation/object-detection"></script>
35
<script>
36
-const img = document.getElementById('img')
37
-const model = await objectDetector.load('/model_web')
38
-const predictions = await model.detect(img)
+ const img = document.getElementById('img')
+ objectDetector.load('/model_web')
+ .then(model => model.detect(img))
39
+ .then(predictions => {
40
+ console.log(predictions)
41
+ })
42
</script>
43
```
44
0 commit comments