A Scriptable widget that shows stock prices and the percentual change from yahoo finance api. Also works with cryptocurrencies.
Setup • Usage • Links • Contribution •
- (if not done yet) Download the scriptable app form AppStore
- In Scriptable create a new script
- Copy the code from script file stock-widget.js
- Create a new widget on homescreen and select this script in scriptable
You can select your stock symbols in 2 different ways:
-
You select the stocks which you want to display in the app through the parameter field. Separate them with ","
-
You can code the stocks directly in the code in function getStockData():
if(args.widgetParameter == null) {
// EDIT: Insert your symbols between the quotation marks
stocks = ["AAPL", "22UA.DE", "GC=F", "BTC-USD"];
} else {
stocks = args.widgetParameter.split(",");
}
Yahoo Finance: https://finance.yahoo.com/
If you have any ideas for extensions or changes just let me know.