[WIP] Getting data from local resource #297
Draft
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What is the best way to get data from a
LocalResource
?For my application, I am treating a Pluto notebook just like a Julia script, and am packaging it alongside some data that is being analyzed. The files are small-medium size, so the
data:
URI technique employed by this package is an ideal fit for export to HTML later.One of the files is a
.csv
file, and I need to parse it. Currently, I am doing something like this with the help of a new method currently in this PR as a straw-man:(One problem with this approach is that it will only work for
Resource
s that are generated using theLocalResource
function; perhaps the type should be forked?)Happy to implement something and propose it here, but I am wondering if there are better ways to do what I am trying to do. Ideas:
PlutoUI.as_text
function in a way I don't yet understandLocalResource
- e.g. if it is going to be deprecated or externalized in the future