Skip to content

Sveltekit migration#188

Open
Azgaar wants to merge 64 commits intomasterfrom
sveltekit
Open

Sveltekit migration#188
Azgaar wants to merge 64 commits intomasterfrom
sveltekit

Conversation

@Azgaar
Copy link
Owner

@Azgaar Azgaar commented Jul 9, 2025

No description provided.

Blipz and others added 30 commits July 25, 2024 01:58
- Improve charge coloring (although two charges of the same type
  will still share the same secondary/tertiary tinctures)
- Support zoom level option
- Support outside charges
- Support inscriptions and font loading
@Blipz
Copy link
Collaborator

Blipz commented Dec 26, 2025

@Azgaar Do you think there is still work to do on this?

@Azgaar
Copy link
Owner Author

Azgaar commented Dec 26, 2025

@Blipz, probably, but it requires some thorough testing. It would be nice if you can summarize the change and issues you see.

@Blipz
Copy link
Collaborator

Blipz commented Dec 27, 2025

Here is a summary of the changes introduced by the PR:

  • Migrate to SvelteKit / Vite
  • Integrate the API, with a new renderer based on a headless browser (allowing for feature parity between app and API)
  • Deploy to a unique Vercel instance
  • Upgrade to Svelte 4

Issues and limitations:

  • Only when running in dev mode and especially with Firefox, the app is noticeably slower at dealing with complex SVG charges
  • A patch to the convert-svg-core package seems to be necessary (handled for now by using patch-package)
  • The new renderer is more costly in terms of processing time than the former one

Untested features:

  • Everything related to MongoDB: seeded COA/claim/unclaim features

@Azgaar
Copy link
Owner Author

Azgaar commented Dec 28, 2025

Thanks, would need to fix the vercel deployment and probably move to a different DB. I don't have full access to MongoDB, they've blocked my account.

@Blipz
Copy link
Collaborator

Blipz commented Mar 3, 2026

Would you consider setting up an integrated MongoDB (or anything else) through Vercel then?

Regarding the deployment errors, I'm lacking access.

@Azgaar
Copy link
Owner Author

Azgaar commented Mar 3, 2026

Vercel has some DBs integrated, and Mongo can also be deployed on Vercel. But it would take time to configure all.

@Azgaar
Copy link
Owner Author

Azgaar commented Mar 3, 2026

Vercel has build error:


> armoria@1.1.0 build
> vite build
/vercel/path0/node_modules/rollup/dist/native.js:64
		throw new Error(
		      ^
Error: Cannot find module @rollup/rollup-linux-x64-gnu. npm has a bug related to optional dependencies (https://github.com/npm/cli/issues/4828). Please try `npm i` again after removing both package-lock.json and node_modules directory.
    at requireWithFriendlyError (/vercel/path0/node_modules/rollup/dist/native.js:64:9)
    at Object.<anonymous> (/vercel/path0/node_modules/rollup/dist/native.js:73:76)
    at Module._compile (node:internal/modules/cjs/loader:1706:14)
    at Object..js (node:internal/modules/cjs/loader:1839:10)
    at Module.load (node:internal/modules/cjs/loader:1441:32)
    at Function._load (node:internal/modules/cjs/loader:1263:12)
    at TracingChannel.traceSync (node:diagnostics_channel:328:14)

@Blipz
Copy link
Collaborator

Blipz commented Mar 3, 2026

Upgrading to Node 24 in the Vercel project's configuration might solve the issue.

@Azgaar
Copy link
Owner Author

Azgaar commented Mar 3, 2026

Still fails with node 24.

The error is:

rendering chunks...
node:internal/event_target:1122
  process.nextTick(() => { throw err; });
                           ^
ReferenceError: SVGPathElement is not defined
    at /vercel/path0/node_modules/path-data-polyfill/path-data-polyfill.js:570:29
    at Object.<anonymous> (/vercel/path0/node_modules/path-data-polyfill/path-data-polyfill.js:1190:3)
    at Module._compile (node:internal/modules/cjs/loader:1761:14)
    at Object..js (node:internal/modules/cjs/loader:1893:10)
    at Module.load (node:internal/modules/cjs/loader:1481:32)
    at Module._load (node:internal/modules/cjs/loader:1300:12)

If would be nice if you can create try to deploy it to your own Vercel account, as I cannot add people there on free plan.

@Azgaar
Copy link
Owner Author

Azgaar commented Mar 7, 2026

@Blipz,

It looks great. How do you see the merge path for Armoria and FMG? I would really want to not break anything, including peoples old .map files. Can we do Armoria first and think about FMG later?

@Blipz
Copy link
Collaborator

Blipz commented Mar 7, 2026

Yes, Armoria can go first. I still have a commit in preparation for allowing NPM packaging, but it currently feels a bit hacky to me.

Regarding FMG, I don't see any reason why that would break .map compatibility but it can wait.

@Blipz
Copy link
Collaborator

Blipz commented Mar 7, 2026

I guess we can merge this if it's fine by you. In this case, it would be useful to make the Vercel URL public and maybe update the Discord bot?

@Azgaar
Copy link
Owner Author

Azgaar commented Mar 7, 2026

Yes, would need to update everything.

@Azgaar
Copy link
Owner Author

Azgaar commented Mar 7, 2026

So it will take time, not going to start today as have like 1 hour time left... But maybe tomorrow.

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.

3 participants