CORS is something that you don’t have a choice about, if you’re doing cross domain requests it’s required.
active_model_serializers is a gem for serialization. You can serialize however you want on the rails side, there are many competeing serialization libraries, or you could just build your json manually, but that’s not a very scalable approach
Thanks.I am new to both of them and i can’t seem to combine them.Tried 2-3 different tutorials but they all error out.I can’t get the full error right now but it is something like this."Reference error.ActiveModelAdapter, must contain one of the following data, model,
ActiveModelAdapter is a third thing that’s only tangentially related. I suggest using some kind of serializer to render json-api, and using the default json-api adapter on the ember side
you mean this “ember serve --proxy localhost:3000” yes and it didn’t work.They connect each other, i see it on the inspector but still same mistake.
Thank You all for helping out.I have gone over a different tutorial Ember and Rails 5 with JSON API: A Modern Bridge - Ember Igniter by Frank Treacy, and it worked perfectly.Special thanks to him for the turorial The one with the CORS was old and i think the part where configuration is made was forgotten but i might be wrong tho.Again, thank you all