ZachJW34 / nx-plus

Collection of Nx Community Plugins
MIT License
302 stars 50 forks source link

@nx-plus/docusaurus with nx@16 #290

Open DerHerrGammler opened 1 year ago

DerHerrGammler commented 1 year ago

nx 16 is out and the update to nx 16 is blocked by the supported range of @nx-plus/docusaurus. Could you update the supported range of nx?

arenier commented 1 year ago

Same problem here

DerHerrGammler commented 1 year ago

I dont now if this is also a valid way for you @arenier but I removed @nx-plus/docusaurus from my project and switched to directly call docusaurus in my configuration of the project.

I configured following package.json in the app project:

{
    "name": "blog",
    "scripts": {
        "serve": "docusaurus start --port 64003 --no-open",
        "build": "docusaurus build --out-dir ../../dist/apps/blog"
    }
}

works totally fine for me eventually also for you instead of using this package

wraeth-eth commented 3 months ago

If using project.json, something like this should work too:

...
  "targets": {
    "build": {
      "executor": "nx:run-commands",
      "options": {
        "command": "docusaurus build --config docusaurus.config.js --out-dir dist",
        "cwd": "<path-to-your-app-package>"
      }
    },
    "serve": {
      "executor": "nx:run-commands",
      "options": {
        "command": "docusaurus start --port 3000 --config docusaurus.config.js",
        "cwd": "<path-to-your-app-package>"
      }
    }
...