openimsdk / docs

OpenIM documentation v3
https://docs.openim.io
MIT License
8 stars 28 forks source link

Build Error due to Broken Links #37

Closed cubxxw closed 9 months ago

cubxxw commented 1 year ago

While executing the npm run build command, the build process failed due to broken links detected by Docusaurus. The error message indicates that there are broken links on pages /sdks/api and the Home Page (/). The detailed error message is as follows:

[ERROR] Unable to build website for locale zh-Hans. [ERROR] Error: Docusaurus found broken links!

Please check the pages of your site in the list below, and make sure you don't reference any path that does not exist. Note: it's possible to ignore broken links with the 'onBrokenLinks' Docusaurus configuration, and let the build pass.

Exhaustive list of all broken links found:

On source page path = /sdks/api: -> linking to docs/sdks/api/msg/index.mdx (resolved as: /sdks/docs/sdks/api/msg/index.mdx)

On source page path = /: -> linking to /restapi/userManagement/userRegister

at throwError (C:\Users\smile\Desktop\web-docs\openim-docs\node_modules@docusaurus\logger\lib\index.js:76:11) ...

Steps to Reproduce:

  1. Clone the repository.
  2. Navigate to the project directory.
  3. Run npm install to install the dependencies.
  4. Run npm run build to build the documentation.

Expected Result:

The documentation should build without any errors.

Actual Result:

The build process fails due to broken links.

Suggested Fix:

Environment:

Additional Context:

Add any other context about the problem here.

Attachments:

image

kubbot commented 10 months ago

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days.

kubbot commented 10 months ago

This issue was closed because it has been stalled for 7 days with no activity.

cubxxw commented 9 months ago
ubuntu@VM-0-4-ubuntu:~/docs$ npm run build 

> openim-docs@1.20.0 build
> docusaurus build

file:///home/ubuntu/docs/node_modules/@docusaurus/core/bin/docusaurus.mjs:30
process.env.BABEL_ENV ??= 'development';
                       ^

SyntaxError: Unexpected token '?'
    at Loader.moduleStrategy (internal/modules/esm/translators.js:133:18)
    at async link (internal/modules/esm/module_job.js:42:21)
ubuntu@VM-0-4-ubuntu:~/docs$ npm version 
{
  'openim-docs': '1.20.0',
  npm: '8.5.1',
  node: '12.22.9',
  v8: '7.8.279.23-node.56',
  uv: '1.43.0',
  zlib: '1.2.11',
  brotli: '1.0.9',
  ares: '1.18.1',
  modules: '72',
  nghttp2: '1.43.0',
  napi: '8',
  llhttp: '2.1.6',
  http_parser: '2.9.4',
  openssl: '1.1.1m',
  cldr: '40.0',
  icu: '70.1',
  tz: '2022a',
  unicode: '14.0'
}