On Sale: GamesAssetsToolsTabletopComics
Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
Tags
(1 edit)

I think I've seen somewhere that it is possible to build a personal website using Decker as the "frontend".  So for example, I could have a GitHub Pages repo with the Web Decker HTML file as index.html and a data file (e.g. a CSV at first) to have a certain degree of decoupling between the data and the app. Is it possible and if so, how can I programmatically (in Lil, e.g. when the main deck loads or when a particular button is pressed) import an external CSV file in the Web-based Decker so I can display it as a table (for a start)?

I hope that my problem is clear and thank you.

It is not possible for an unmodified copy of web-decker to programmatically fetch external files hosted e.g. somewhere on github pages, make http requests, etc. Doing this sort of thing would require adding custom javascript extensions to web-decker. An example of how such an extension might be written can be found in this subthread.

In general, decks should be self-contained objects pre-packed with any data they require to operate. A deck is a database, with grid widgets for storing tables and Lil for querying and manipulating them.

Lilt can be used to import or export data to or from a .deck or .html file in an automated fashion. If you insist on storing some dataset independently from a deck that uses it, it might be possible to use Lilt as part of a continuous integration pipeline or "build script" to bake out an updated web-decker build when an associated csv file is changed.