-
Notifications
You must be signed in to change notification settings - Fork 196
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
Feature: URL base/URL subpath support #1131
base: main
Are you sure you want to change the base?
Conversation
@zefhemel lint problems should be fixed in the appended commit. Restart the check will you please? |
Good start, testing this right now let me post my findings:
|
I noticed that I have to prefix my prefix with a |
Using the
Sends me to |
Sync mode doesn't seem to work at all (try switching to it by using the Sync button at the top right). And after being in Sync mode, disabling it breaks everything until I manually unregister the service worker. |
It seems there is still a long way to go before completely usable. Do I need to work on this alone or the project members will also provide assistance? |
I think I am doing it wrong. In most cases urls need to remain relative instead of getting a prefix injection everywhere. I will look into it by weekend. |
@zefhemel the latest commit fixes most of the url jumping problems you metioned earlier. And the sync mode appeared to function out of box after I applied the latest upstream update (without any modifications on my end). |
Just did a bit more testing and many of the issues I reported remain. Do you need help? I can probably take this over, can't promise immediately though. |
Yes please take over |
As discussed in issue #163 , the base URL feature is required to host silverbullet through reverse proxy without the need of subdomain, enabling the usage of some port proxy such as ngrok.
In this implementation, the url prefix is read from environment variable
SB_URL_PREFIX
, and passed to the client by text substitutions inindex.html
.I did many coarse batch substitution in like
http_sever.ts
without fine tests, so it might need to be carefully looked into.