Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

x-model custom element isn't working on React App!! #23

Open
AbulKalamAZ opened this issue Oct 10, 2020 · 2 comments
Open

x-model custom element isn't working on React App!! #23

AbulKalamAZ opened this issue Oct 10, 2020 · 2 comments

Comments

@AbulKalamAZ
Copy link

I have been trying to work with x-model custom element in my react app, but it's behavior was quite unexpected. When I copy model-element.min.js file from github and link it to my app root using script tag. It responds with a html file, maybe that's why I find the following error in my console

  • model-element.js:1 Uncaught SyntaxError: Unexpected token '<'
@keithclark
Copy link
Owner

Hi. Do you have an example I can look at?

@AbulKalamAZ
Copy link
Author

I was trying to render a OBJ model using x-model custom element in a react app. But after few unsuccessful attempts, I have replaced it with three.js. If you want I can make you an example. Actually I wasn't able to import all the required JS files in a react component, while i was trying to import it, it was returning some sort of html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants