GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||
GeezerVison is showing github.com — feat(serve): --base-path serves docs from a subpath to match GitHub pages by iamdanfox · Pull Request #47 · docsifyjs/docsify-cli ConversationBefore this PRUsing a window.$docsify = { name: 'my-project', basePath: '/my-project', } After this PRI'll be able to run fixes #32 cc @davestewart who originally filed the issue
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions
Author
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
|
There was an error while loading. Please reload this page.
|
Great PR.. Is there another way around this for local development? EDIT: For anyone else reading, my workaround was to dynamically set base path depending on |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Good idea, just needs conflicts resolved.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
A workaround is to use another static serve like apache or nginx, and configure the root path in one of those. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Unfortunately, it seems like the popular NPM packages for static serving don't support this feature. Unless I overlooked it, |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
@trusktr It's supported via middleware. It should be possible to rewrite all requests matching the configured path. e.g.
And so on. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
Seems like what we should do is instead of building our own static server CLI with defaults, allow any options to be passed to the underlying tool, support passing in middleware, and maybe have our own default set of middleware if we need. Thoughts? EDIT: even if we were to do this later, I'm still in favor of merging this PR. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
I fixed that for the moment using Running command: Maybe when I'll get some time will fix the CI and complete the PR |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
Add root path to serve
There was an error while loading. Please reload this page.