{"action":"created","issue":{"url":"https://api.github.com/repos/JarvusInnovations/jarvus-postgrest-apikit/issues/5","labels_url":"https://api.github.com/repos/JarvusInnovations/jarvus-postgrest-apikit/issues/5/labels{/name}","comments_url":"https://api.github.com/repos/JarvusInnovations/jarvus-postgrest-apikit/issues/5/comments","events_url":"https://api.github.com/repos/JarvusInnovations/jarvus-postgrest-apikit/issues/5/events","html_url":"https://github.com/JarvusInnovations/jarvus-postgrest-apikit/issues/5","id":101231419,"number":5,"title":"Row fetches can finish before fields query","user":{"login":"timwis","id":761444,"avatar_url":"https://avatars.githubusercontent.com/u/761444?v=3","gravatar_id":"","url":"https://api.github.com/users/timwis","html_url":"https://github.com/timwis","followers_url":"https://api.github.com/users/timwis/followers","following_url":"https://api.github.com/users/timwis/following{/other_user}","gists_url":"https://api.github.com/users/timwis/gists{/gist_id}","starred_url":"https://api.github.com/users/timwis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timwis/subscriptions","organizations_url":"https://api.github.com/users/timwis/orgs","repos_url":"https://api.github.com/users/timwis/repos","events_url":"https://api.github.com/users/timwis/events{/privacy}","received_events_url":"https://api.github.com/users/timwis/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-08-16T03:48:27Z","updated_at":"2015-08-21T10:08:52Z","closed_at":null,"body":"I'm noticing that my app consistently finishes `store.load()` before the `OPTIONS` request in `model/Postgrest.js`. Is there any way to hook to the `OPTIONS` event completing from my view? I was looking for some event that gets fired by `model.addFields()` perhaps, but there don't appear to be any."},"comment":{"url":"https://api.github.com/repos/JarvusInnovations/jarvus-postgrest-apikit/issues/comments/133363057","html_url":"https://github.com/JarvusInnovations/jarvus-postgrest-apikit/issues/5#issuecomment-133363057","issue_url":"https://api.github.com/repos/JarvusInnovations/jarvus-postgrest-apikit/issues/5","id":133363057,"user":{"login":"timwis","id":761444,"avatar_url":"https://avatars.githubusercontent.com/u/761444?v=3","gravatar_id":"","url":"https://api.github.com/users/timwis","html_url":"https://github.com/timwis","followers_url":"https://api.github.com/users/timwis/followers","following_url":"https://api.github.com/users/timwis/following{/other_user}","gists_url":"https://api.github.com/users/timwis/gists{/gist_id}","starred_url":"https://api.github.com/users/timwis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/timwis/subscriptions","organizations_url":"https://api.github.com/users/timwis/orgs","repos_url":"https://api.github.com/users/timwis/repos","events_url":"https://api.github.com/users/timwis/events{/privacy}","received_events_url":"https://api.github.com/users/timwis/received_events","type":"User","site_admin":false},"created_at":"2015-08-21T10:08:52Z","updated_at":"2015-08-21T10:08:52Z","body":"So I added a `console.log()` [just before](https://github.com/JarvusInnovations/jarvus-postgrest-apikit/blob/master/src/model/Postgrest.js#L43) and [just after](https://github.com/JarvusInnovations/jarvus-postgrest-apikit/blob/master/src/model/Postgrest.js#L94) the `OPTIONS` request, as well as [just before](https://github.com/timwis/ext-postgrest-crud/blob/master/app/view/main/List.js#L43)/after my store load. In development, the former always begins & ends before the latter begins. In production, both begin around the same time and the store ends first. See console log with timestamps below.\r\n\r\n<img width=\"387\" alt=\"screen shot 2015-08-21 at 06 05 29\" src=\"https://cloud.githubusercontent.com/assets/761444/9406047/06d0e602-47cb-11e5-8ce8-5d3deab9a8da.png\">\r\n\r\nI'm thinking of firing an event on the model when the `OPTIONS` request completes and listening to that event. Let me know if this is off-base."}}