What is the principle behind retrieving JSON data from this link via your local machine?

Tell us what’s happening:

I understand what does this code does, but how do I get it to run from my local machine whilst using Atom. I’m trying to understand the principles behind how to get this to work.


  return $.ajax({
    headers: {
      Accept: "application/json"
    url: 'https://gist.githubusercontent.com/camperbot/5a022b72e96c4c9585c32bf6a75f62d9/raw/e3c6895ce42069f0ee7e991229064f167fe8ccdc/quotes.json',
    success: function(jsonQuotes) {
      if (typeof jsonQuotes === 'string') {
        quotesData = JSON.parse(jsonQuotes);

Your browser information:

User Agent is: Chrome

Using atom and local machine doesn’t have to do anything with running your ajax.

Atom is just a tool to help you write code, it also won’t matter if you are running your code in local machine or on a server.

What error are you getting?