Hi,
I just wanted to share an early alpha version of an app I made with Anvil. It allows users to upload and store a csv file online, and to get a short link to the file and a QR code.
Feedback is welcome.
The background is that I often teach courses where I want the students to have access to csv files. I could use GitHub, Dropbox or Google Drive, but it has some drawbacks.
-
Auto-download not default
I want a link to the csv that the students can use in R or Python. For instance, they should be able to write df = pd.read_csv(LINK). The link you get from GitHub and Google Drive are not like that. They give you links to ‘views’ of the file, not auto-download. Now, it is possible to modify the links to make them auto-download, but this introduces an extra complication that beginner students should not have to deal with. And the links are long! -
Complex
Academics who write articles and want to share their data should have an easy way of doing so. Unfortunately, not everybody know how to use GitHub and they may not want to register. An app like this could provide an easier option.
But mainly I just wanted to try out things. Maybe it is useful, maybe not so much. In any case it was fun to build it.
Here are some of my own lessons:
-
Simplify!
There is always a tendency to try to add lots of features. In order to finish, I eventually had to throw a lot of this away. For instance, I wanted to allow the user to choose between two types of links for the file they upload. One ‘view’ link and another ‘download’ link. But then I had to explain the difference, and the business logic later on would depend on the choice - and many binary choices like that soon led to an exponential complexity. For instance, having some options as ‘paid’ options and some as ‘free’ was another complexity. The solution was often: Simplify! I dropped the ‘view’ option (since GitHub or Google Drive already has this), made it free and restricted the files to ‘csv’ and not all kinds of files. -
Staff, Documentation, Forum (and Anvil) are great
I got great help from lots of people. Connecting it to my own domain required some help, as did a bug in Blob media (that require encoding and binary files), and to solve some of my own misunderstandings (believing that an Image could be sent to a server function as an URLMedia object). I could never have built someting like this without help, and not at all if I had to learn Jacascript, back-end development/integration, deployment at the same time. Thanks! -
Custom components
There are some great custom components presented in different places. The drag-and-drop file loader, for instance (Thanks!). I also missed a richer text element (that allowed markup), and found two. And a script to copy text to the clipboard (great!). More of these deserve to be collected in one place and perhaps given more prominence and an even simpler way to add them to a project.