vuetable-2-tutorial
vuetable-2-tutorial copied to clipboard
lesson 01 problems
Hello!
I have error
XMLHttpRequest cannot load http://vuetable.ratiw.net/api/users?sort=&page=1&per_page=10. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://vuetable.example.test' is therefore not allowed access.
How can I fix it?
One more question. Why we need jquery in this lesson?
@itelmenko Sorry, the lesson hasn't been updated to Vuetable v1.6 yet. The reference to the sample API endpoint should be done via "https:" instead of just "http:". So, if you change the api-url
to as follow it should work.
<vuetable ref="vuetable"
api-url="https://vuetable.ratiw.net/api/users"
></vuetable>
jQuery is needed for Semantic UI framework that uses in this tutorial.
Thank you for you answer. But look like it is cross domain issue (it is for https also):
XMLHttpRequest cannot load https://vuetable.ratiw.net/api/users?sort=&page=1&per_page=10. Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://vuetable.example.test' is therefore not allowed access.