-
Notifications
You must be signed in to change notification settings - Fork 17
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
Rewriting paths #13
Comments
Sorry for my very late answer. I'm not sure this issue is related to this plugin. The image paths are not computed by the includes. |
I'm trying to use this in a Vuepress site, and I've only been able to get one combination of actual image location and path in Markdown to work. I've tried:
Only the third option has worked for me so far. Unfortunately this model is antithetical to the idea of the include, because I'll need to make sure that image is available (even if only by symlink) in a corresponding |
I believe I'm having a similar issue - I'm trying to include a markdown file inside an included markdown file. An example below:
Unfortunately, when including include2.md, it tries to load it from both main.md and include1.md, so that it tries to load /docs/include2.md and /docs/docs/include.md. |
I am experiencing the same problem as @emiyl . Has anyone found a solution to including files that include other files? |
Assuming you're in
/opt/doc/file.md
and you include./included/first.md
, but that file has an inline image referencing./img/logo.gif
, the resulting Markdown would be looking for/opt/doc/img/logo.gif
, while the image is actually at/opt/doc/included/img/logo.gif
.Would it be possible (via a config flag or similar) to get the plugin to scan included files and rewrite any paths discovered accordingly? Something like
path.resolve(basePath, path.resolve(path.dirname(path.join(basePath, importPath))
should do the trick, assumingbasePath
is the path of the parent file andimportPath
is the path of the imported file.The text was updated successfully, but these errors were encountered: