LuxDL / DocumenterVitepress.jl

Documentation with Documenter.jl and VitePress
https://luxdl.github.io/DocumenterVitepress.jl/
MIT License
63 stars 9 forks source link

Build vitepress directly without relying on package.json in writer #105

Closed asinghvi17 closed 1 month ago

asinghvi17 commented 3 months ago

@lazarusA this should fix the Julia build

lazarusA commented 3 months ago

ohh.. this was not merged in the latest release. Testing this branch now. Ohh my bad.

YES. I works!!!

lazarusA commented 3 months ago

There is still something not right:

> docs:dev
> vitepress dev _build/html/en/.documenter

failed to start server. error:
Error: You need to install `markdown-it-mathjax3` to use math support.
    at createMarkdownRenderer (file:///Users/lalonso/node_modules/vitepress/dist/node/serve-BTRXZ1g2.js:37405:13)
    at async localSearchPlugin (file:///Users/lalonso/node_modules/vitepress/dist/node/serve-BTRXZ1g2.js:41795:14)
    at async createVitePressPlugin (file:///Users/lalonso/node_modules/vitepress/dist/node/serve-BTRXZ1g2.js:42426:5)
    at async createServer (file:///Users/lalonso/node_modules/vitepress/dist/node/serve-BTRXZ1g2.js:63811:14)
    at async createDevServer (file:///Users/lalonso/node_modules/vitepress/dist/node/cli.js:405:20)
asinghvi17 commented 3 months ago

How did you run that last thing exactly?

lazarusA commented 3 months ago

as it is: https://github.com/lazarusA/julia/tree/la/docs

in the root dir:

make docs

fails to build. I need to go into doc and do npm i first , and then

make docs

works.

and as usual in

doc> npm run docs:dev

to see the site.

lazarusA commented 3 months ago

and if you want to test your branch (without the npm i step),

change line 9 in the make.jl file by

Pkg.add(PackageSpec(url="https://github.com/LuxDL/DocumenterVitepress.jl", rev="as/better_build"))
asinghvi17 commented 3 months ago

huh. I'm like 90% sure we run npm i but maybe it's in the wrong place.

lazarusA commented 3 months ago

yeah, npm i its ran internally. But for some reason when calling make docs it fails to do so. It only copies the packages.json file (if not available), but after that it's not doing the installation.

asinghvi17 commented 1 month ago

I think the issue here is that it was probably using the wrong version of node or something, there were a bunch of recent issues about that.