diff --git a/requirements.txt b/requirements.txt index d1e4c48..bf29577 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,3 +1,4 @@ requests coreapi flask +flask-cors diff --git a/server.py b/server.py index f13a670..7af2fb7 100644 --- a/server.py +++ b/server.py @@ -1,10 +1,12 @@ from collections import OrderedDict from coreapi import Document, Link, Error, Field, dump from flask import Flask, Response, request +from flask.ext.cors import CORS import uuid app = Flask(__name__) +CORS(app) # We store all the notes in a mapping of UUIDs to dictionary instances. # In a real system we would be using a database or other persistent backend.