skeleton icon indicating copy to clipboard operation
skeleton copied to clipboard

NEXT: investigate Vike for use in our sandbox apps

Open endigo9740 opened this issue 1 year ago • 6 comments

Currently the Skeleton sandbox test apps for each component package are setup as follows:

  • Svelte: SvelteKit
  • React: Vite/React + third party router

In order to move to a more uniform structure for both these and other frameworks in the future we should investigate Vike:

  • https://vike.dev/

This is a meta-framework built on top of Vite that provides a simple file-based route that should work consistently across all framework. This appears to cover all requirements we need for these dev-focused apps.

endigo9740 avatar Aug 15 '24 20:08 endigo9740

@Hugos68 pinging you as you recommended this and might could use an assist in testing @AdrianGonz97 we might need your help updating the NPM deployment process for either package if we go with this.

Note this is low priority. Just something to investigate when we have the bandwidth.

endigo9740 avatar Aug 15 '24 20:08 endigo9740

I've done some testing and the results are so far very pleasant. Vike is extremely unopinonated, it just gives us a router and the rest of the project is for us left to fill/utilize.

I've created an example repo using React here: https://github.com/Hugos68/skeleton-vike

Vike supports the following frameworks by default:

On top of that there are community adapters for more niece frameworks but I think this should cover our needs.

In the README of the project is the file structure explained but I'll send it here again for showcase:

├── package.json
├── pnpm-lock.yaml
├── README.md
├── src
|  ├── components
|  |  └── Counter.tsx
|  └── pages
|     ├── +config.ts
|     └── index
|        └── +Page.tsx
├── tsconfig.json
└── vite.config.ts

Hugos68 avatar Aug 17 '24 19:08 Hugos68

Very cool. Again, not a huge priority since what we have is working. But I think we should evaluate switching before launch. Definitely before we introduce Vue.

@bartduisters just FYI!

endigo9740 avatar Aug 17 '24 23:08 endigo9740

Any reason it's low prio? I wouldn't mind working on this. Makes developing a little bit better and makes it easier to contribute as all the projects will be identical.

Hugos68 avatar Aug 18 '24 10:08 Hugos68

We could technically go all the way to launch with our current configuration. I'd rather focus on tasks blocking launch first. That said, if this could have any potential affect to the release process then we should do that while the project is still in a "work in progress" state.

endigo9740 avatar Aug 18 '24 17:08 endigo9740

Understandable, I'll park this mentally then for now

Hugos68 avatar Aug 19 '24 08:08 Hugos68

Unfortunately Vike has pivoted since I last reviewed and now only supports React/Vue/Solid. This means we would still have an outlier with Svelte/Kit.

Given this, I'd say we follow Hugo's suggestion (from Discord discussions) and review splitting the component packages from their integrated Playground. Mirroring this after the upcoming Tailwind v4 PR which introduces a new Astro playground to pair with the core plugin package.

I've detailed all the specifics in a new ticket here. ETA for this will likely fall AFTER the v3 launch.

  • https://github.com/skeletonlabs/skeleton/issues/3194

endigo9740 avatar Feb 04 '25 18:02 endigo9740