Deezer API and ThreeJS don't work together

41 views Asked by At

Can't load glb models after adding Deezer API script: https://e-cdn-files.dzcdn.net/js/min/dz.js

Loading glb model:

const loader = new GLTFLoader()
loader.load('mymodel.glb', ...)

Then getting this error:

open-model.vue:274 model loading error: SyntaxError: Unexpected token 'o', "[object Rea"... is not valid JSON
at JSON.parse (<anonymous>)
at GLTFLoader.parse (GLTFLoader.js:344:1)
at Object.eval [as onLoad] (GLTFLoader.js:239:1)
at eval (three.module.js:43612:1)

Once I remove Deezer script - everything works fine

Update: Figured out that there is some problem with VueJS and Deezer, deezer API somehow interrupts VueJS data

0

There are 0 answers