-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
data path references https://toolness.github.io/p5.js-widget/* if using with loadTable, etc. #39
Comments
also, forgive my ignorance, but is there an easy way of compiling the typescript dependencies into one lib js file? |
Oh, sorry, I just noticed this issue--for some reason GitHub isn't emailing me when new issues are filed or something. Good catch! Hmmm, there are multiple ways to tackle this... let me think a bit and get back to you.
Hmm, I'm not quite sure what you mean--what are you trying to accomplish? Are you trying to self-host the widget on your own server, or something else? |
Yea, in this specific case, I'm looking to self host all files from a GitHub. Repo and use raw git as a static file server. I use this for most of my tutorials because its quick and simple to organize from my course repo |
Ah, gotcha--I've spun that off into #45! |
Ok, I think I've fixed this! You can read about the new behavior here: https://toolness.github.io/p5.js-widget/#base-url Let me know if this works for you! |
Sorry for the delayed response. Any chace base-url can work with relative paths? For example if I'm developing on localhost but push my code somewhere else, it would be great to have data-base-url="./" to map to the root directory where my index.html lives. |
No worries! I Just added this in 81835ae. Note, though, that if you just want the base URL to be the same path as the page you're embedding the widget in, you shouldn't have to provide |
If I'm using loadTable, loadXML, etc. functions with this widget src'ed from your github (for example):
then the data path will reference toolness.github instead of my local index. This is potentially a problem since it will likely break any user code expecting to load data from my local index, resulting in a 404. Example:
Is there an easy fix to this other than srcing the widget from my local index?
The text was updated successfully, but these errors were encountered: