Open theGeekyLad opened 2 years ago
I've updated the branch and merged all commits. Please let me know if it's alright.
@theGeekyLad I think the share functionality isn't working can u please check again.
@Zack-Dx the share functionality only works in a deployed environment as the API calls need to go from an https
-based site to the Pastebin API without which we get the CORS error.
Momentarily, for testing, you could launch Chrome with the --disable-web-security
flag as follows, to test the functionality:
google-chrome --disable-web-security --user-data-dir=0
Pastebin Integration
Using the Pastebin API, notes can now be easily shared with a direct URL. Here's what it looks like:
Setup
You'll need a Pastebin API Developer Key, which can be setup entirely for free on the Pastebin API website, for this to work. The key string can be pasted as the value of the
pastebinDevKey
constant on the first line of the index.js file.Circumventing CORS
The server environment that hosts the website must support CORS for the Pastebin API to work or, alternatively, Google Chrome (and similarly other browsers) can be launched with the
--disable-web-security
flag as follows:google-chrome --disable-web-security --user-data-dir=0
(on Linux)Where the '0' at the end can either be left as is, or be made to point to the data directory for another user.