[PR #3639] [CLOSED] feat: unified package #4045

Closed
opened 2026-04-25 00:18:06 +02:00 by adam · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/advplyr/audiobookshelf/pull/3639
Author: @wommy
Created: 11/22/2024
Status: Closed

Base: masterHead: feat-unifiedPackage


📝 Commits (1)

📊 Changes

335 files changed (+20810 additions, -22634 deletions)

View changed files

📝 .gitignore (+2 -3)
📝 assets/absicons.css (+0 -0)
📝 assets/app.css (+0 -0)
📝 assets/defaultStyles.css (+0 -0)
📝 assets/draggable.css (+0 -0)
📝 assets/ebooks/basic.js (+0 -0)
📝 assets/ebooks/htmlParser.js (+0 -0)
📝 assets/ebooks/mobi.js (+0 -0)
📝 assets/fonts.css (+0 -0)
📝 assets/tailwind.css (+0 -0)
📝 assets/transitions.css (+0 -0)
📝 assets/trix.css (+0 -0)
client/package-lock.json (+0 -19144)
client/package.json (+0 -46)
📝 components/app/Appbar.vue (+0 -0)
📝 components/app/BookShelfCategorized.vue (+0 -0)
📝 components/app/BookShelfRow.vue (+0 -0)
📝 components/app/BookShelfToolbar.vue (+0 -0)
📝 components/app/ConfigSideNav.vue (+0 -0)
📝 components/app/LazyBookshelf.vue (+0 -0)

...and 80 more files

📄 Description

Brief summary

unified client/package.json into root package.json

Which issue is fixed?

no specific issue,

but because there arent two package.json's anymore,
everything can just be ran from rootDir
eliminates the need for two npm ci's
simplifies the install and generation of the app

in the migration from nuxt 2 to 3, 3 comes with a /server/ directory
https://nuxt.com/docs/guide/directory-structure/server

tho i will still have to migrate all the logic from express into nitro and h3
https://h3.unjs.io/examples/from-expressjs-to-h3

i think it will be well worth it: removing dozens of outdate dependencies and boilerplate code, while simplifying logic and getting a nice speed increase

ill post a nice chatgpt analysis of that whenever my credits refill tomorrow

In-depth Description

  • cd client
  • git mv assets components layouts middleware mixins pages players plugins store strings cypress cypress.config.js nuxt.config.js tailwind.config.js ..
  • mv dist public static .nuxt ..
  • cd ..
  • here i copied the scripts, dependencies: deps, dev, and optional, from client/package.json into package.json, plus a few other misc edits, check the file
  • git rm -r client/
  • changed the line in server/Server.js from /client/dist/ to /dist/
  • changed the .gitignore
  • ran npm install so npmci would work
  • also ran npm audit fix to fix the fixable npm errors 59 => 42 cli link
  • and ran npm dedupe to remove ~75 duplicated packages from node_modules cli link

How have you tested this?

yes of course,

  • rm -rf node_modules
  • npm run client ; npm start
  • hit localhost:3333

and everything was perfectly there

i only have an epub and an audiobook, but they both played perfectly,

i navigated to each different view they all work normally,
which tracks because i didnt edit anything on the server
other than removing the /client prefix from the static app directory

Screenshots

no client changes


Additional - Left Undone - Unsure How to Proceed

i didnt edit a few misc files, ill split them into categories

simple

  • .devcontainer/post-create.sh, .vscode/launch.json, .vscode/tasks.json
    • need slight tweaks
  • .dockerignore
    • seems like the same few line changes from .gitignore

medium

  • Dockerfile
    • dunno how STAGE 0 WORKDIR works, looks simple tho
    • probs similar to the next one

harder

  • .github/workflows
    • probs just swap /client w/ assets components layouts middleware mixins pages players plugins static store strings cypress cypress.config.js nuxt.config.js tailwind.config.js

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/advplyr/audiobookshelf/pull/3639 **Author:** [@wommy](https://github.com/wommy) **Created:** 11/22/2024 **Status:** ❌ Closed **Base:** `master` ← **Head:** `feat-unifiedPackage` --- ### 📝 Commits (1) - [`0f42a4d`](https://github.com/advplyr/audiobookshelf/commit/0f42a4d58031fd14cfb130843907e2849dd7078c) feat: unified package ### 📊 Changes **335 files changed** (+20810 additions, -22634 deletions) <details> <summary>View changed files</summary> 📝 `.gitignore` (+2 -3) 📝 `assets/absicons.css` (+0 -0) 📝 `assets/app.css` (+0 -0) 📝 `assets/defaultStyles.css` (+0 -0) 📝 `assets/draggable.css` (+0 -0) 📝 `assets/ebooks/basic.js` (+0 -0) 📝 `assets/ebooks/htmlParser.js` (+0 -0) 📝 `assets/ebooks/mobi.js` (+0 -0) 📝 `assets/fonts.css` (+0 -0) 📝 `assets/tailwind.css` (+0 -0) 📝 `assets/transitions.css` (+0 -0) 📝 `assets/trix.css` (+0 -0) ➖ `client/package-lock.json` (+0 -19144) ➖ `client/package.json` (+0 -46) 📝 `components/app/Appbar.vue` (+0 -0) 📝 `components/app/BookShelfCategorized.vue` (+0 -0) 📝 `components/app/BookShelfRow.vue` (+0 -0) 📝 `components/app/BookShelfToolbar.vue` (+0 -0) 📝 `components/app/ConfigSideNav.vue` (+0 -0) 📝 `components/app/LazyBookshelf.vue` (+0 -0) _...and 80 more files_ </details> ### 📄 Description <!-- For Work In Progress Pull Requests, please use the Draft PR feature, see https://github.blog/2019-02-14-introducing-draft-pull-requests/ for further details. If you do not follow this template, the PR may be closed without review. Please ensure all checks pass. If you are a new contributor, the workflows will need to be manually approved before they run. --> ## Brief summary <!-- Please provide a brief summary of what your PR attempts to achieve. --> unified `client/package.json` into root `package.json` ## Which issue is fixed? <!-- Which issue number does this PR fix? Ex: "Fixes #1234" --> no specific issue, but because there arent two `package.json`'s anymore, everything can just be ran from rootDir eliminates the need for two `npm ci`'s simplifies the install and generation of the app in the migration from nuxt 2 to 3, 3 comes with a `/server/` directory https://nuxt.com/docs/guide/directory-structure/server tho i will still have to migrate all the logic from express into nitro and h3 https://h3.unjs.io/examples/from-expressjs-to-h3 i think it will be well worth it: removing dozens of outdate dependencies and boilerplate code, while simplifying logic and getting a nice speed increase ill post a nice chatgpt analysis of that whenever my credits refill tomorrow ## In-depth Description <!-- Describe your solution in more depth. How does it work? Why is this the best solution? Does it solve a problem that affects multiple users or is this an edge case for your setup? --> - `cd client` - `git mv assets components layouts middleware mixins pages players plugins store strings cypress cypress.config.js nuxt.config.js tailwind.config.js ..` - `mv dist public static .nuxt ..` - `cd ..` - here i copied the `scripts`, dependencies: `deps`, `dev`, and `optional`, from `client/package.json` into `package.json`, plus a few other misc edits, check the file - `git rm -r client/` - changed the line in `server/Server.js` from `/client/dist/` to `/dist/` - changed the `.gitignore` - ran `npm install` so `npmci` would work - also ran `npm audit fix` to fix the fixable npm errors 59 => 42 [cli link](https://docs.npmjs.com/cli/v10/commands/npm-audit) - and ran `npm dedupe` to remove ~75 duplicated packages from `node_modules` [cli link](https://docs.npmjs.com/cli/v10/commands/npm-dedupe) ## How have you tested this? <!-- Please describe in detail with reproducible steps how you tested your changes. --> yes of course, - `rm -rf node_modules` - `npm run client ; npm start` - hit `localhost:3333` and everything was perfectly there i only have an epub and an audiobook, but they both played perfectly, i navigated to each different view they all work normally, which tracks because i didnt edit anything on the server other than removing the `/client` prefix from the static app directory ## Screenshots <!-- If your PR includes any changes to the web client, please include screenshots or a short video from before and after your changes. --> no client changes --- ### Additional - Left Undone - Unsure How to Proceed i didnt edit a few misc files, ill split them into categories #### simple - `.devcontainer/post-create.sh`, `.vscode/launch.json`, `.vscode/tasks.json` - need slight tweaks - `.dockerignore` - seems like the same few line changes from `.gitignore` #### medium - `Dockerfile` - dunno how `STAGE 0 WORKDIR` works, looks simple tho - probs similar to the next one #### harder - `.github/workflows` - probs just swap `/client` w/ `assets components layouts middleware mixins pages players plugins static store strings cypress cypress.config.js nuxt.config.js tailwind.config.js` --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
adam added the pull-request label 2026-04-25 00:18:06 +02:00
adam closed this issue 2026-04-25 00:18:06 +02:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/audiobookshelf#4045