Skip to content

pkp/pkp-lib#13870 Use ui-library as npm workspace for all dependencies - #6117

Open
jardakotesovec wants to merge 4 commits into
pkp:mainfrom
jardakotesovec:i13870
Open

jardakotesovec wants to merge 4 commits into
pkp:mainfrom
jardakotesovec:i13870

Conversation

@jardakotesovec

@jardakotesovec jardakotesovec commented Nov 24, 2026 •

Copy link
Copy Markdown
Member

For pkp/pkp-lib#13870
Requires pkp/ui-library#1063

The application now includes lib/ui-library as an npm workspace and declares no npm dependencies of its own. All dependencies, including jquery, swiper, altcha, cypress and the closure compiler, are declared in ui-library's package.json.

  • package.json:
    • adds "workspaces": ["lib/ui-library"];
    • removes dependencies, devDependencies and the vite overrides;
    • adds an npm run sync-lock script that regenerates package-lock.json from ui-library's lockfile.
  • package-lock.json: generated by npm run sync-lock. Production dependencies keep the versions of the previous OJS lockfile. For OMP and OPS, that means small updates to OJS's versions: vue 3.5.18 → 3.5.22, primevue 4.3.7 → 4.4.0, luxon 3.7.1 → 3.7.2.
  • The vite configs are unchanged. resolve.dedupe stays for now: removing it would change the bundle, because reka-ui would use its own @vueuse/core 14.
  • lib/ui-library submodule: in separate commits, to be updated once pkp/pkp-lib#13870 Make ui-library the single list of npm dependencies ui-library#1063 is merged.

npm install now installs into a single node_modules in the application root. There is no lib/ui-library/node_modules any more. For OJS, the build output is byte-identical to the old setup.

To update a dependency, follow the steps in ui-library's README ("Dependencies" section): change it in ui-library, update the submodule here, run npm run sync-lock, then npm install.

…e dedupe

Regenerate package-lock.json from the ui-library lockfile, which now keeps
the production dependency versions of the previous OJS lockfile.

Restore resolve.dedupe in the vite configs. Removing it changes the bundle
(reka-ui would use its own @vueuse/core 14 instead of the deduped 10), so it
is left for a separate change.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant