Mentions of this being experimental in
- overview page (first in the docs)
- readme of solid-start package
---------
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Removes
- react-start-server-functions-fetcher/handler/client/ssr
- solid-start-server-functions-fetcher/handler/client/ssr
Introduces (as they were called in the past)
- start-server-functions-fetcher/handler/client/ssr
The API routes only rely on h3, which is in start-server-core, so the
entire start-api-routes package can now be agnostic.
Removes
- react-start-api-routes
- solid-start-api-routes
Introduces
- start-api-routes
The original `@tanstack/router-devtools` package still work - it's not
touch by this PR in any way, apart from a migration note saying:
>[@tanstack/router-devtools] Warning: This package has moved to
@tanstack/react-router-devtools. Please switch to the new package, as
this package will be dropped soon.
This introduce three new packages
- @tanstack/router-devtools-core : This is a SolidJS port of the UI
And two adapters on top, that mount this solid app and forward
router/routerState into it.
- @tanstack/solid-router-devtools
- @tanstack/router-router-devtools
For use of devtools in production, a `TanStackRouterDevtoolsInProd` can
be imported instead of the standard `TanStackRouterDevtools` that'll be
tree shaken away in prod.
---------
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: SeanCassiere <33615041+SeanCassiere@users.noreply.github.com>
Co-authored-by: Lachlan Collins <1667261+lachlancollins@users.noreply.github.com>
This PR introduce support for Solid to be used with TanStack Start.
There are several ongoing refactors that can influence the timing of
when it's most feasible to merge this.
### Status (build and run e2e/solid-start/basic)
- [X] SSR
- [x] API Routes
- [x] Server Functions
- [x] HMR
- [x] Streaming (/stream route)
- [X] Timely hydration
### Ongoing refactors
Refactor to make router packages (aka. client-only features) more
agnostic:
- #3552
- #3540
- #3538
- #3171
Refactor to make start packages (aka. server features) more agnostic:
- #3546
- #3563
- #3565
### Upstream changes to solid-router
- #3592
- #3591
- #3589
- #3616
### Passing E2E test suites
- [x] basic
- [x] website
- [x] scroll-restoration
- [x] server-functions
---------
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Brenley Dueck <brenleydueck@gmail.com>
Co-authored-by: Iha Shin <me@xiniha.dev>
Co-authored-by: Brenley Dueck <brenley@crowdbotics.com>
* copy react-router
* update
* Move forward branch
* cleanup
* cleanup
* add publish
* bump deps
* ci: apply automated fixes
* remove unused imports
* ci: apply automated fixes
* bump vite plugin solid
* fix imports
* ci: apply automated fixes
* remove react lint from solid-router
* fix types
* ci: apply automated fixes
* add structuralSharing
* downgrade vite plugin solid
* fix scroll-restoration in solid-router
* fix Transitioner
* fix imports from ScrollRestoration
* Fix tests
* Fix more tests
* Remove the react $$typeof
* add accessors to useLocation
* add remountDeps
* cleanup
* remove tanstack/store
* format
* add missing call to setupScrollRestoration
* format
* add optional
* align match component
* make matches a signal
* Bump vite-plugin-solid to stable
* add missing await
* Fix unknown error
* Tweak the tests to call functions
* remove unused vars
* fix lockfile
* Down to 25 failures
* Remove .only
* call search()
* remove the structuralSharing
* fix type test
* fix structuralSharing
* comment out structured sharing validation check
* fix typings
* comment out serialization check
* comment out serialization check
* cleanup
* improve types of useSearch
* fix "when setting search params with 2 parallel navigate calls"
* fix useParams
* fix types
* fix useParams types
* cleanup debug
* fix link data loader
* fix data loader signal
* fix type test
* fix Link "when navigating away from a route with a loader that errors"
* setup on() simpler
* make initial load a createRenderEffect
* Fix some link preload tests
* add accessor to UseMatchRoute
* fix: when navigating to /posts with a beforeLoad that returns context
* call parentRouteId
* re-enable invariant
* fix when navigating from /invoices to ./invoiceId and the current route is /posts/$postId/details
* use memo for prev
* remove browserhistory workaround
* fix "after a navigation, should have emitted the "onResolved" event twice"
* skip remount
* add types to useSearch
* fix search middleware
* don't need a getter
* sync react-router
* solid kitchen sink
* add the example to workspace
* lockfile
* fix solid kitchensink name
* add solid template
* fix example
* rename react to solid
* work on example
* add accessor
* fix type tests
* Fix login in example
* Don't destructure
* Fix stuck on pending component
* Fix where loaderData can be undefined
* Use For component
* More refactor
* Hacky way to fix loading spinner
* Fix one test
* Better MatchRoute fix
* Down to 1 failing test
* Fix last test
* cleanup subscription
* lockfile
* eslint
* ci: apply automated fixes
* fix router-core lint
* ci: apply automated fixes
* add e2e test for solid-router
* ci: apply automated fixes
* work on solid-router e2e suites
* fix comment
* use solid-virtualizer
* work on scroll-restauration
* work on scroll-restauration
* skip react-specific useRenderEffect test
* fix errorcomponent being used before it's defined
* set solid target for esbuild
* ci: apply automated fixes
* fix rspack tests
* fix query tets
* add solid-query example
* use memo for post
* add memo for posts
* fix example
* add jsx compiler flags to esbuild commands
* add esbuild-plugin-solid
* Fix some e2e
* ci: apply automated fixes
* port #3423 from react-router
* fix useLoaderData test-d
* add codeSplitGroupings
* Scroll restoration fixes
* add asset headcontent script
* remove solid-router-copy
* fix react use
* fix scroll restoration test
* skip esbuild because it's broken in react-router
* wait for timeout
* update scroll-restoration to match react
* useLocation
* use on() in match
* align useNavigate with react-router
* lockfile
* fix Scripts test
* align __TSR_SSR__ in ScriptOnce
* remove solid-router from publish
* lint
* ci: apply automated fixes
* align to react-router
* port over "exclude props from state equality check to prevent history push for equal url and state"
* align with react-router
* add shouldThrow
* fix typePrimitives
* use searchStr to fix the search middleware
* ci: add solid-router to the labeler
* use patched vite-plugin-solid
* eslint
* ci: apply automated fixes
* use vite-plugin-solid 2.11.2
* remove only modifier
* move vite-plugin-solid peerDep to router-plugin
* use latest vite-plugin-solid
* move vitest to root
* bump vitest
* revert onRendered
* lint
* add to publish
* fix scroll restoration
* ci: apply automated fixes
* align version with react-router
* sync to react-router
* sync with react-router
* sync navigate tests to react-router
* ci: apply automated fixes
* use Solid.JSX.Element consistently instead of Solid.JSXElement
* remove irrelevant test
* ci: apply automated fixes
* remove unused suite
* lint
---------
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Brenley Dueck <brenleydueck@gmail.com>
Co-authored-by: SeanCassiere <33615041+SeanCassiere@users.noreply.github.com>
* feat: scaffold the new `@tanstack/router-plugin` package
* chore: include in the overrides
* feat: more scaffolding
* test: just a random test that'll be removed later
* build: hopefully fixes build
* style: import order
* chore: peer deps for router-plugin
* feat: setup the generator
* refactor: combined needs to be done for the individual plugin
* chore: copy all the babel stuff over from router-vite-plugin
* feat: copy the babel plugin setup from router-plugin
* feat: enfore pre
* refactor: turn the error into its own custom one
* style: eslint
* style: more eslint
* chore: update the readme
* copy the router-vite-plugin into start-vite-plugin
* test: remove the tests we dont need
* export config-name from generator
* undo that last one
* reduce this down
* eliminate the router logic
* undo the touches to the generator and cli
* move this down here
* eslint
* chore: remove deps that are not needed
* test: test for createServerFn being renamed during the destructured import
* fix: handle destructured rename case
* test: handle star imports
* chore: push
* chore: remove this