webdoc-labs / webdoc

Documentation generator for the web
https://www.webdoclabs.com
Other
79 stars 9 forks source link

Class-index.html issue when specifying a root folder #177

Closed obiot closed 2 years ago

obiot commented 2 years ago

I guess related to #175 , but when specifying a root folder (doc": "mkdirp docs && webdoc --quiet --site-root melonJS/docs -R README.md" in my case), the Class-index.html is generated at the wrong location.

in my setting it should be : /melonJS/docs/Class-index.html instead I have : /melonJS/docs/melonjs/docs/Class-index.html

output path is doubled

obiot commented 2 years ago

Hi @ShukantPal this is actually still not working,

now instead of creating the files under /melonJS/docs/Class-index.html it is created under /melonJS/docs/docs/Class-index.html

also the styling sheet from my theme is now ignored <link type="text/css" rel="stylesheet" href="/docs/styles/index.css" />

where it should be as below (like for index.html and others) <link type="text/css" rel="stylesheet" href="/melonJS/docs/styles/index.css" />

ShukantPal commented 2 years ago

@obiot i haven't made a new release afaik with the fix. Did you test the master branch?

obiot commented 2 years ago

I had to manually move and edit the file when publishing the latest doc.

I now 3 different manual operations :P

obiot commented 2 years ago

@obiot i haven't made a new release afaik with the fix. Did you test the master branch?

yes I'm on the latest version

obiot commented 2 years ago

it's actually more than the styling sheet: [Error] Failed to load resource: the server responded with a status of 404 (Not Found) (default-template.js, line 0) [Error] Failed to load resource: the server responded with a status of 404 (Not Found) (md.css, line 0) [Error] Failed to load resource: the server responded with a status of 404 (Not Found) (index.css, line 0) [Error] Failed to load resource: the server responded with a status of 404 (Not Found) (header.css, line 0) [Error] Failed to load resource: the server responded with a status of 404 (Not Found) (index.css, line 0)

http://melonjs.github.io/melonJS/docs/Class-Index.html

ShukantPal commented 2 years ago

Hmmm. Let me see - I didn't change much in 1.6.6

ShukantPal commented 2 years ago

Hi @ShukantPal this is actually still not working,

now instead of creating the files under /melonJS/docs/Class-index.html it is created under /melonJS/docs/docs/Class-index.html

also the styling sheet from my theme is now ignored <link type="text/css" rel="stylesheet" href="/docs/styles/index.css" />

where it should be as below (like for index.html and others) <link type="text/css" rel="stylesheet" href="/melonJS/docs/styles/index.css" />

@obiot I think you changed the --site-root 5 days ago https://github.com/melonjs/melonJS/commit/683a3dfc8d12b377cfbcc3b1ef44377e4dc67936

That's why it was linking to /docs. I still have #175 on the roadmap. The Class-Index fix hasn't been released yet :)

obiot commented 2 years ago

Hi @ShukantPal this is actually still not working, now instead of creating the files under /melonJS/docs/Class-index.html it is created under /melonJS/docs/docs/Class-index.html also the styling sheet from my theme is now ignored <link type="text/css" rel="stylesheet" href="/docs/styles/index.css" /> where it should be as below (like for index.html and others) <link type="text/css" rel="stylesheet" href="/melonJS/docs/styles/index.css" />

@obiot I think you changed the --site-root 5 days ago melonjs/melonJS@683a3df

That's why it was linking to /docs. I still have #175 on the roadmap. The Class-Index fix hasn't been released yet :)

indeed, but I just changed it back locally to generate the "public" doc version. and with the previous melonJS/docs/ the result is as what I mentioned/wrote about here

ShukantPal commented 2 years ago

@obiot Does installing 1.6.5 fix the issue?

obiot commented 2 years ago

I'm on version 1.6.6 now actually. that did not fix the issue. these last few comments are based on this last 1.6.6 version and a locally server root set to melonJS/docs

ShukantPal commented 2 years ago

@obiot Yes - that's why I ask if 1.6.5 fixes the issue :) - cause I think it was working for you on 1.6.5 previously

obiot commented 2 years ago

no it was not, remember the Class-index file was in another totally different folder (melonJS/docs/melonjs/docs), It actually never worked since the first time I uploaded the files on the web. Locally it was though (using a local server but only "docs" as server root).

ShukantPal commented 2 years ago

@obiot Yeah the Class-Index is still broken and the fix will go out in 1.6.7 but isn't published. I'm talking about the new issues you're reporting here

obiot commented 2 years ago

the new issue related to Class-index was the styling sheet not being set to the provided theme, for the rest I already opened ticket for them (#176 and #175, actually if you could managed to fix the latter it would probably fix issues with Class-index and absolute path).

obiot commented 2 years ago

I feel for you though man, I hate those path issues :)

obiot commented 2 years ago

shall we re-open this issue if still broken ? just to make sure it stays under the radar, thanks.

ShukantPal commented 2 years ago

I'm working on webdoc stuff in the other repo - it's fixed in master :). I'll release once I'm done with some parser fixes and the 2.0 milestone