Skip to content

Implement data structure/injection for Promise/etc #6

@aubreypwd

Description

@aubreypwd

Eric is going to mockup the UI in #3 and he's going to use the Axios framework to build out requests to specific data sets, e.g. lists, items, etc that are just dummy data. I should be able to use those datasets fed into Axios to construct API endpoints that Axios can also hit using .get( URI ) to get similar data.

We decided to go with Axios because of the promise structure it uses. Which, instead of trusting the common jQuery Ajax request to handle what happens via the complete or success callbacks, we can let the Ajax request simply finish, while Axios's .then waits until it resolves and passes back data.

The real decision to go with Axios is twofold:

  1. To move the response to the AJAX request out of the Ajax request's success function, to the .then function of the caller
  2. To use the Promise system going forward
  3. Axios allows us to make two or more requests to data, yet allow us to handle them both using a single .then

Metadata

Metadata

Assignees

Labels

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions