This is a sample application which can help extract your expenses via the HTML content picked up from the Spendee website.
I was using Spendee application for recording my expenses. I needed to export my expenses into an excel file inorder to perform some simple analytics.
I realized that the application allows us to export only the expenses of the last 365 days for free account users. That's when I wrote this simple parser to get my older expenses.
- Since this is really dependent on the web application's css structure, if Spendee makes changes to their website, it is likely that this script will need some changes.
- This is a purely react application and it doesn't upload your data anywhere. The code necessary to extract the expenses and to format it into excel file is written in javascript and hence your data will not leave your system.
- React Bootstrap
- To get the UI CSS libraries
- Command to install -
npm install react-bootstrap bootstrap
- Tutorial - https://react-bootstrap.netlify.app/getting-started/introduction/
- Cheerio
- To parse HTML content
- Command to install -
npm i cheerio
- Package - https://www.npmjs.com/package/cheerio
- Tutorial - https://stackoverflow.com/questions/54136046/how-to-read-and-parse-html-in-nodejs
- To create a downloadable csv file using javascript - https://www.javatpoint.com/javascript-create-and-download-csv-file
- Clone this repository in your machine.
- Download and install Node, which also includes NPM (Node Package Manager) - https://nodejs.org/en/
- Open your command prompt, navigate to this repository.
- Run the command
npm start
- We can now access the web application in your browser by navigating to http://localhost:3000
This is purely an academic exercise. A small side project to help me understand react and a few other concepts with a working example.
Code released under the MIT license