From c1363fe938ab94281272cad8939b892fd705a803 Mon Sep 17 00:00:00 2001 From: Alec Aivazis Date: Sat, 15 Oct 2022 02:21:16 -0700 Subject: [PATCH] Split into houdini and houdini-svelte (#593) * initial layout * move runtime * there are only packages * start turbo * start on houdini plugins * add fsPatch to houdini-svelte * plugins can modify index files * move houdini into src * redlines * more redlines * more redlines * start unifying build tasks * runtimes aren't bundled * unify structure more * build non-standard directories as submodules * both packages build (with type errors) * fix imports * comment out watch-and-run * start converting to rollup * go back to esbuild * import svelte plugin directly * remove cyclic dependency * move recursive copy * start generating typedefs * fix typescript lib config * move kit filepath conventions to houdini-svelte * more kit consolidation * houdini core typechecks :tada: * remove flatten fs export * more fs imports * clean up deps * non transform page script related type issues * houdini-svelte typechecks * only emit typedefs * fix more circular imports * plugins can be imported * plugins need to be built to be imported * move codegen out of cmd * add config to vite adapter * add typedefs to generated runtime * runtime generation to svelte plugin * start on filepath conventions * fix ciruclar impots * more ciruclar deps cleared up * fixed issue in svelte transform * start on tests * add houdini/test * fixed some test type errors * update package.json * fix type error from merge * make fs_patch mix more clear * consolidate extraction logic * centralize plugin option config * svelte runtime can import core * new line when generating typescript index file * better newline behavior * fix parsing erors * svelte plugin generates stores in plugin_root * snapshot * fix relative paths and include fragments * it all builds :tada: * remove plugin envar check since its static analysis now * update package.json * runtime typedefs * fix setSession exports * fix some more imports * remove extensions * fix timing issue with the fs patch * everything but preview layouts * fix preview errors * rename integration tests as end-to-end * example builds * update example * update pnpm lock file * rename houdini-svelte to houdini-plugin-svelte * fix imports in e2e tests * fix imports in tests * update vite setup imports * more test fixes * add root deps * fix includeFile call * update versions * add root deps * tests run * add pkg commands * build command now compiles and generates typedefs * use turbo publish pipeline when publishing changeset * remove artifact snapshot with normal inline extension * houdini-svelte tests need to run through full pipeline * and then there was one * there isn't a single version any more to welcome users to :( * fix siteURL references * fix imports * add lint * remove svelte-kit sync * move some dev deps to deps in sit * update pnpm lock * only compile for tests * build before e2e tests * build e2e * add type reference * triple slash -> import * fix adapter location * add reference back * local def for runtime * turn off @typescript-eslint/no-namespace * fix typedef for plugins * fix relative imports in generate typedefs * remove more lint rules * remove framework from config * plugin config embedded in config file * can't use framework config to identify v16 * use external watch and run * remove conflicting type * fix framework passed to unit tests * convert playwright config to js * refresh lock file * integration tests run locally * centralize config file logic in runtime * move svelte specific config to svelte plugin * update configs in exaple and e2e tests * remove unused file * fix quiet errors check * update tests * add 0.17.0 release notes * add houdini-svelte as a depencey in init * update setting-up guide * fix package descriptions * move changelog * use correct package.json version * revert pnpm-lock * fix component query docs * +layout.gql (#601) * :children_crossing: IMPROVE: integration tests with layout ideas * :construction: UPDATE: types generated * :construction: UPDATE: layout_query_path * :construction: UPDATE: tmp while no Lyaout_User * :white_check_mark: DOC: update * :sparkles: NEW: +page & +layout * :white_check_mark: NEW: tests * :pencil2: DOC: one line doc * :pencil2: UPDATE: changeset * :white_check_mark: NEW: eae test * :children_crossing: IMPROVE: display the correct file that has an issue (including +page|+layout) * add changeset * move generate command to its own file * remove deprecated cli args * always export package.json * update release notes to use the new setSession * start trasnform_runtime api * consolidate runtime transforms * fix path of cjs runtime * update docs * more doc updates Co-authored-by: JYC --- .changeset/proud-hairs-trade.md | 5 + .changeset/wild-coats-hang.md | 6 + .eslintrc.cjs | 5 +- .github/workflows/tests.yml | 32 +- .gitignore | 10 +- .graphqlrc.yaml | 8 +- .npmignore | 5 - .npmrc | 3 + .prettierignore | 3 +- {integration => e2e/sveltekit}/.eslintrc.cjs | 0 {integration => e2e/sveltekit}/.gitignore | 0 {integration => e2e/sveltekit}/.prettierrc | 0 e2e/sveltekit/README.md | 1 + .../sveltekit}/api/graphql.mjs | 0 .../sveltekit}/api/schema-hello.graphql | 0 .../sveltekit}/api/schema.graphql | 0 {integration => e2e/sveltekit}/api/server.mjs | 0 .../sveltekit}/houdini.config.js | 8 +- {integration => e2e/sveltekit}/package.json | 17 +- .../sveltekit}/playwright.config.ts | 6 +- {integration => e2e/sveltekit}/src/app.d.ts | 0 {integration => e2e/sveltekit}/src/app.html | 0 .../sveltekit}/src/hooks.server.ts | 4 +- .../sveltekit}/src/lib/QueryComponent.svelte | 0 .../sveltekit}/src/lib/QueryExt.svelte | 0 .../src/lib/graphql/houdiniClient.ts | 0 .../lib/graphql/operations/FRAG.UserInfo.gql | 0 .../graphql/operations/MUTATION.AddUser.gql | 0 .../operations/MUTATION.EnumMutation.gql | 0 .../operations/MUTATION.UpdateUser.gql | 0 .../MUTATION.UpdateUserSubUnsub.gql | 0 .../lib/graphql/operations/QUERY.Hello.gql | 0 .../graphql/operations/QUERY.MultiUser.gql | 0 .../src/lib/graphql/operations/QUERY.User.gql | 0 .../graphql/operations/QUERY.UsersList.gql | 0 .../operations/QUERY.UsersListSubUnsub.gql | 0 .../operations/QUERY.usersListComp.gql | 0 .../sveltekit}/src/lib/utils/routes.ts | 3 + .../sveltekit}/src/lib/utils/testsHelper.ts | 0 .../sveltekit}/src/routes/+error.svelte | 0 .../sveltekit}/src/routes/+layout.svelte | 4 +- .../sveltekit}/src/routes/+page.svelte | 0 .../sveltekit}/src/routes/index/spec.ts | 0 .../src/routes/layouts/+layout.svelte | 0 .../src/routes/layouts/+page.svelte | 0 .../src/routes/layouts/layout/spec.ts | 0 .../src/routes/layouts/page2/+page.svelte | 0 .../fragment/backwards-cursor/+page.svelte | 0 .../fragment/backwards-cursor/spec.ts | 0 .../fragment/forward-cursor/+page.svelte | 0 .../fragment/forward-cursor/spec.ts | 0 .../pagination/fragment/offset/+page.svelte | 0 .../routes/pagination/fragment/offset/spec.ts | 0 .../query/backwards-cursor/+page.svelte | 0 .../pagination/query/backwards-cursor/spec.ts | 0 .../query/forward-cursor/+page.svelte | 0 .../pagination/query/forward-cursor/spec.ts | 0 .../query/offset-variable/+page.svelte | 0 .../pagination/query/offset-variable/+page.ts | 0 .../pagination/query/offset-variable/spec.ts | 0 .../pagination/query/offset/+page.svelte | 0 .../routes/pagination/query/offset/spec.ts | 0 .../src/routes/plugin/+layout.svelte | 0 .../sveltekit}/src/routes/plugin/+layout.ts | 0 .../routes/plugin/fragment/update/+page.js | 0 .../plugin/fragment/update/+page.svelte | 0 .../src/routes/plugin/fragment/update/spec.ts | 0 .../plugin/load/inlineAndGlobal/+page.js | 0 .../plugin/load/inlineAndGlobal/+page.svelte | 0 .../plugin/load/inlineAndGlobal/spec.ts | 0 .../src/routes/plugin/load/list/+page.js | 0 .../src/routes/plugin/load/list/+page.svelte | 0 .../src/routes/plugin/load/list/spec.ts | 0 .../plugin/load/pageQuery-session/+page.gql | 0 .../load/pageQuery-session/+page.svelte | 0 .../plugin/load/pageQuery-session/spec.ts | 0 .../routes/plugin/load/pageQuery/+page.gql | 0 .../routes/plugin/load/pageQuery/+page.svelte | 0 .../src/routes/plugin/load/pageQuery/spec.ts | 0 .../src/routes/plugin/load/single/+page.js | 0 .../routes/plugin/load/single/+page.svelte | 0 .../src/routes/plugin/load/single/spec.ts | 0 .../plugin/query/afterLoad/+page.svelte | 0 .../routes/plugin/query/afterLoad/+page.ts | 0 .../src/routes/plugin/query/afterLoad/spec.ts | 0 .../plugin/query/beforeLoad/+page.svelte | 0 .../routes/plugin/query/beforeLoad/+page.ts | 0 .../routes/plugin/query/beforeLoad/spec.ts | 0 .../plugin/query/component/+page.svelte | 0 .../src/routes/plugin/query/component/spec.ts | 0 .../routes/plugin/query/layout/+layout.svelte | 0 .../routes/plugin/query/layout/+page.svelte | 0 .../routes/plugin/query/layout/layout/spec.ts | 0 .../routes/plugin/query/multiple/+page.svelte | 0 .../src/routes/plugin/query/multiple/spec.ts | 0 .../routes/plugin/query/onError/+page.svelte | 0 .../src/routes/plugin/query/onError/+page.ts | 0 .../src/routes/plugin/query/onError/spec.ts | 0 .../routes/plugin/query/scalars/+page.svelte | 0 .../src/routes/plugin/query/scalars/spec.ts | 0 .../routes/plugin/query/simple/+page.svelte | 0 .../src/routes/plugin/query/simple/spec.ts | 0 .../plugin/query/variable-[id]/+page.svelte | 0 .../plugin/query/variable-[id]/+page.ts | 0 .../routes/plugin/query/variable-[id]/spec.ts | 0 .../plugin/query/variables-error/+page.js | 0 .../plugin/query/variables-error/+page.svelte | 0 .../plugin/query/variables-error/spec.ts | 0 .../src/routes/query-param/+error.svelte | 12 + .../src/routes/query-param/+page.server.ts | 10 + .../src/routes/query-param/Loading.svelte | 32 + .../src/routes/query-param/UserName.svelte | 25 + .../query-param/user-[userId]/+layout.gql | 6 + .../query-param/user-[userId]/+layout.svelte | 59 + .../query-param/user-[userId]/+layout.ts | 5 + .../query-param/user-[userId]/+page.server.ts | 11 + .../query-param/user-[userId]/birth/+page.gql | 6 + .../user-[userId]/birth/+page.svelte | 31 + .../query-param/user-[userId]/birth/+page.ts | 6 + .../user-[userId]/friends/+page.gql | 12 + .../user-[userId]/friends/+page.svelte | 16 + .../user-[userId]/friends/+page.ts | 12 + .../routes/query-param/user-[userId]/spec.ts | 20 + .../sveltekit}/src/routes/spec.ts | 0 .../stores/endpoint-query/+page.server.ts | 0 .../routes/stores/endpoint-query/+page.svelte | 0 .../src/routes/stores/endpoint-query/spec.ts | 0 .../routes/stores/fragment-null/+page.svelte | 0 .../src/routes/stores/fragment-null/spec.ts | 0 .../src/routes/stores/metadata/+page.svelte | 2 + .../src/routes/stores/metadata/spec.ts | 2 +- .../routes/stores/mutation-enums/+page.svelte | 0 .../src/routes/stores/mutation-enums/spec.ts | 0 .../stores/mutation-scalars/+page.svelte | 0 .../routes/stores/mutation-scalars/spec.ts | 0 .../stores/mutation-update/+page.svelte | 2 +- .../routes/stores/mutation-update/+page.ts | 0 .../src/routes/stores/mutation-update/spec.ts | 0 .../src/routes/stores/mutation/+page.svelte | 0 .../src/routes/stores/mutation/spec.ts | 0 .../+page.svelte | 0 .../network-one-store-multivariables/spec.ts | 0 .../src/routes/stores/network/+page.svelte | 0 .../src/routes/stores/network/spec.ts | 0 .../StoreForwardCursorPaginationQuery.gql | 0 .../query/forward-cursor/+page.svelte | 0 .../pagination/query/forward-cursor/spec.ts | 0 .../src/routes/stores/partial/partial/spec.ts | 0 .../routes/stores/partial/partial_List.gql | 0 .../stores/partial/partial_List/+page.svelte | 0 .../stores/partial/partial_List/+page.ts | 0 .../stores/partial/partial_[userId].gql | 0 .../partial/partial_[userId]/+page.svelte | 0 .../stores/partial/partial_[userId]/+page.ts | 2 +- .../stores/partial/partial_[userId]_Light.gql | 0 .../partial_[userId]_Light/+page.svelte | 0 .../partial/partial_[userId]_Light/+page.ts | 2 +- .../stores/prefetch-[userId]/+page.svelte | 0 .../routes/stores/prefetch-[userId]/+page.ts | 2 +- .../routes/stores/prefetch-[userId]/spec.ts | 0 .../src/routes/stores/session/+page.svelte | 0 .../src/routes/stores/session/spec.ts | 0 .../routes/stores/ssr-[userId]/+page.svelte | 0 .../src/routes/stores/ssr-[userId]/+page.ts | 2 +- .../src/routes/stores/ssr-[userId]/spec.ts | 0 .../ssr-one-store-multivariables/+page.svelte | 0 .../ssr-one-store-multivariables/+page.ts | 0 .../ssr-one-store-multivariables/spec.ts | 0 .../src/routes/stores/ssr/+page.svelte | 1 - e2e/sveltekit/src/routes/stores/ssr/+page.ts | 15 + .../sveltekit}/src/routes/stores/ssr/spec.ts | 0 .../routes/stores/subunsub-list/+page.svelte | 0 .../src/routes/stores/subunsub-list/spec.ts | 0 .../stores/subunsub-mutation/+page.svelte | 0 .../src/routes/stores/withComp/+page.svelte | 0 .../sveltekit}/static/favicon.png | Bin .../sveltekit}/svelte.config.js | 0 {integration => e2e/sveltekit}/tsconfig.json | 0 {integration => e2e/sveltekit}/vite.config.js | 0 example/houdini.config.js | 6 +- example/package.json | 19 +- example/src/lib/ItemEntry.svelte | 4 +- example/src/routes/+layout.js | 5 - example/src/routes/[filter]/+page.svelte | 46 +- example/src/routes/[filter]/+page.ts | 24 + example/src/routes/addItem/+page.svelte | 9 - example/svelte.config.js | 2 + example/tsconfig.json | 7 +- example/vite.config.js | 1 - houdini.d.ts | 4 + integration/README.md | 1 - integration/src/routes/stores/ssr/+page.ts | 9 - package.json | 143 +- packages/_scripts/build.js | 147 + packages/_scripts/main.js | 10 + packages/_scripts/package.json | 22 + packages/_scripts/typedefs.js | 94 + packages/houdini-svelte/package.json | 57 + .../src/plugin/codegen}/adapter.ts | 14 +- .../src/plugin/codegen/index.ts | 22 + .../src/plugin/codegen/kit/index.ts | 310 + .../src/plugin/codegen}/kit/kit.test.ts | 123 +- .../src/plugin/codegen}/stores/fragment.ts | 19 +- .../src/plugin/codegen}/stores/index.ts | 27 +- .../src/plugin/codegen}/stores/mutation.ts | 16 +- .../src/plugin/codegen}/stores/query.test.ts | 156 +- .../src/plugin/codegen}/stores/query.ts | 20 +- .../plugin/codegen}/stores/subscription.ts | 20 +- .../houdini-svelte/src/plugin/extract.test.ts | 2 +- .../houdini-svelte/src/plugin/extract.ts | 48 +- .../src/plugin}/extractLoadFunction.test.ts | 22 +- .../src/plugin}/extractLoadFunction.ts | 24 +- .../houdini-svelte/src/plugin}/fsPatch.ts | 102 +- packages/houdini-svelte/src/plugin/imports.ts | 28 + packages/houdini-svelte/src/plugin/index.ts | 169 + packages/houdini-svelte/src/plugin/kit.ts | 385 + .../src/plugin}/transforms/index.ts | 34 +- .../src/plugin}/transforms/kit/index.ts | 13 +- .../src/plugin}/transforms/kit/init.test.ts | 8 +- .../src/plugin}/transforms/kit/init.ts | 28 +- .../src/plugin}/transforms/kit/load.test.ts | 201 +- .../src/plugin}/transforms/kit/load.ts | 97 +- .../plugin}/transforms/kit/session.test.ts | 42 +- .../src/plugin}/transforms/kit/session.ts | 29 +- .../src/plugin}/transforms/query.test.ts | 16 +- .../src/plugin}/transforms/query.ts | 39 +- .../src/plugin}/transforms/reactive.ts | 12 +- .../src/plugin}/transforms/tags.ts | 21 +- .../src/plugin/transforms/types.ts | 9 + .../src/plugin/validate.test.ts | 18 +- .../houdini-svelte/src/plugin/validate.ts | 31 +- .../houdini-svelte/src/preprocess/index.ts | 33 + .../houdini-svelte/src}/runtime/adapter.ts | 3 - .../houdini-svelte/src/runtime/fragments.ts | 20 +- .../houdini-svelte/src/runtime}/index.ts | 13 +- .../houdini-svelte/src/runtime/network.ts | 6 + .../houdini-svelte/src/runtime/session.ts | 187 + .../src}/runtime/stores/fragment.ts | 8 +- .../src}/runtime/stores/index.ts | 0 .../src}/runtime/stores/mutation.ts | 14 +- .../src}/runtime/stores/pagination/cursor.ts | 20 +- .../src}/runtime/stores/pagination/fetch.ts | 5 +- .../runtime/stores/pagination/fragment.ts | 11 +- .../src}/runtime/stores/pagination/index.ts | 0 .../src}/runtime/stores/pagination/offset.ts | 18 +- .../stores/pagination/pageInfo.test.ts | 0 .../runtime/stores/pagination/pageInfo.ts | 5 +- .../src}/runtime/stores/pagination/query.ts | 12 +- .../src}/runtime/stores/query.ts | 52 +- .../src}/runtime/stores/store.ts | 7 +- .../src}/runtime/stores/subscription.ts | 12 +- packages/houdini-svelte/src/runtime/types.ts | 40 + packages/houdini-svelte/src/test/index.ts | 209 + CHANGELOG.md => packages/houdini/CHANGELOG.md | 0 packages/houdini/package.json | 80 + packages/houdini/src/cmd/generate.ts | 63 + packages/houdini/src/cmd/index.ts | 52 + {src => packages/houdini/src}/cmd/init.ts | 36 +- .../houdini/src}/cmd/pullSchema.ts | 3 +- .../generators/artifacts/artifacts.test.ts | 2946 ++ .../codegen}/generators/artifacts/fieldKey.ts | 2 +- .../codegen}/generators/artifacts/index.ts | 19 +- .../generators/artifacts/indexFile.ts | 6 +- .../codegen}/generators/artifacts/inputs.ts | 7 +- .../generators/artifacts/operations.ts | 11 +- .../generators/artifacts/pagination.test.ts | 660 + .../generators/artifacts/policy.test.ts | 294 + .../generators/artifacts/selection.ts | 8 +- .../generators/artifacts/utils.test.ts | 0 .../codegen}/generators/artifacts/utils.ts | 4 +- .../generators/definitions/enums.test.ts | 15 +- .../codegen}/generators/definitions/enums.ts | 10 +- .../codegen}/generators/definitions/index.ts | 6 +- .../generators/definitions/schema.test.ts | 251 + .../houdini/src/codegen}/generators/index.ts | 3 +- .../src/codegen/generators/indexFile/index.ts | 66 + .../generators/indexFile}/indexFile.test.ts | 13 +- .../generators/persistedQueries/index.ts | 5 +- .../persistedQueries/persistedQuery.test.ts | 13 +- .../codegen/generators/runtime/index.test.ts | 18 +- .../src/codegen/generators/runtime/index.ts | 69 + .../generators/runtime/runtime.test.ts | 26 + .../typescript/addReferencedInputTypes.ts | 8 +- .../codegen}/generators/typescript/index.ts | 38 +- .../generators/typescript/inlineType.ts | 10 +- .../generators/typescript/typeReference.ts | 4 +- .../codegen}/generators/typescript/types.ts | 12 +- .../generators/typescript/typescript.test.ts | 365 +- .../houdini/src/codegen/index.ts | 223 +- .../src/codegen}/transforms/addID.test.ts | 5 +- .../houdini/src/codegen}/transforms/addID.ts | 9 +- .../transforms/composeQueries.test.ts | 14 +- .../src/codegen}/transforms/composeQueries.ts | 5 +- .../transforms/fragmentVariables.test.ts | 64 +- .../codegen}/transforms/fragmentVariables.ts | 10 +- .../houdini/src/codegen}/transforms/index.ts | 0 .../houdini/src/codegen}/transforms/list.ts | 56 +- .../src/codegen}/transforms/lists.test.ts | 37 +- .../src/codegen}/transforms/paginate.test.ts | 922 +- .../src/codegen}/transforms/paginate.ts | 147 +- .../src/codegen}/transforms/schema.test.ts | 6 +- .../houdini/src/codegen}/transforms/schema.ts | 5 +- .../src/codegen}/transforms/typename.test.ts | 5 +- .../src/codegen}/transforms/typename.ts | 7 +- .../houdini/src/codegen}/utils/commonjs.ts | 0 .../src/codegen}/utils/flattenSelections.ts | 2 +- .../src/codegen}/utils/graphql.test.ts | 2 +- .../houdini/src/codegen}/utils/graphql.ts | 10 +- .../houdini/src/codegen}/utils/index.ts | 1 - .../src/codegen}/utils/moduleExport.ts | 4 +- .../houdini/src/codegen}/utils/murmur.ts | 2 +- .../houdini/src/codegen}/validators/index.ts | 2 +- .../src/codegen}/validators/noIDAlias.test.ts | 8 +- .../src/codegen}/validators/noIDAlias.ts | 3 +- .../houdini/src/codegen/validators/plugins.ts | 25 + .../src/codegen}/validators/typeCheck.test.ts | 26 +- .../src/codegen}/validators/typeCheck.ts | 33 +- .../codegen}/validators/uniqueNames.test.ts | 8 +- .../src/codegen}/validators/uniqueNames.ts | 4 +- .../houdini/src/lib}/cleanupFiles.ts | 8 +- .../houdini/src/lib}/config.test.ts | 0 .../houdini/src/lib}/config.ts | 529 +- packages/houdini/src/lib/constants.ts | 1 + .../houdini/src/lib}/error.ts | 0 .../common => packages/houdini/src/lib}/fs.ts | 117 +- .../houdini/src/lib}/graphql.test.ts | 0 .../houdini/src/lib}/graphql.ts | 0 .../houdini/src/lib}/imports.ts | 38 +- .../houdini/src/lib}/index.ts | 7 +- .../houdini/src/lib}/introspection.ts | 6 +- packages/houdini/src/lib/parse.ts | 17 + .../houdini/src/lib}/pipeline.ts | 0 packages/houdini/src/lib/types.ts | 34 + .../houdini/src/lib}/walk.ts | 7 +- .../houdini/src}/runtime/cache/cache.ts | 33 +- .../houdini/src}/runtime/cache/gc.ts | 7 +- packages/houdini/src/runtime/cache/index.ts | 3 + .../houdini/src}/runtime/cache/lists.ts | 0 .../houdini/src}/runtime/cache/storage.ts | 4 +- .../houdini/src}/runtime/cache/stuff.ts | 0 .../src}/runtime/cache/subscription.ts | 0 .../runtime/cache/tests/availability.test.ts | 2 +- .../src}/runtime/cache/tests/gc.test.ts | 2 +- .../src}/runtime/cache/tests/keys.test.ts | 0 .../src}/runtime/cache/tests/list.test.ts | 2 +- .../runtime/cache/tests/readwrite.test.ts | 2 +- .../src}/runtime/cache/tests/scalars.test.ts | 2 +- .../src}/runtime/cache/tests/storage.test.ts | 0 .../runtime/cache/tests/subscriptions.test.ts | 2 +- .../houdini/src}/runtime/index.ts | 15 +- .../houdini/src}/runtime/lib/config.ts | 150 +- .../houdini/src}/runtime/lib/constants.ts | 2 +- .../houdini/src}/runtime/lib/deepEquals.ts | 0 .../houdini/src}/runtime/lib/errors.ts | 0 packages/houdini/src/runtime/lib/index.ts | 8 + .../houdini/src}/runtime/lib/log.ts | 2 +- packages/houdini/src/runtime/lib/network.ts | 240 + .../houdini/src}/runtime/lib/scalars.test.ts | 149 +- .../houdini/src}/runtime/lib/scalars.ts | 3 +- .../houdini/src}/runtime/lib/types.ts | 56 +- .../houdini/src/test/index.ts | 128 +- {src => packages/houdini/src}/vite/ast.ts | 1 - packages/houdini/src/vite/houdini.ts | 112 + {src => packages/houdini/src}/vite/imports.ts | 66 +- {src => packages/houdini/src}/vite/index.ts | 36 +- {src => packages/houdini/src}/vite/schema.ts | 13 +- pnpm-lock.yaml | 22675 ++++++---------- pnpm-workspace.yaml | 2 +- rollup.config.js | 48 - runtimeMeta.js | 11 - site/package.json | 8 +- site/src/routes/api/query.svx | 11 +- site/src/routes/guides/authentication.svx | 4 +- site/src/routes/guides/caching-data.svx | 37 +- site/src/routes/guides/contributing.svx | 94 +- site/src/routes/guides/pagination.svx | 4 +- site/src/routes/guides/persisted-queries.svx | 18 +- site/src/routes/guides/release-notes.svx | 59 + .../routes/guides/setting-up-your-project.svx | 10 +- site/src/routes/guides/typescript.svx | 2 +- .../routes/guides/working-with-graphql.svx | 7 +- .../generators/artifacts/artifacts.test.ts | 2975 -- .../generators/artifacts/pagination.test.ts | 665 - src/cmd/generators/artifacts/policy.test.ts | 299 - src/cmd/generators/definitions/schema.test.ts | 225 - src/cmd/generators/kit/index.ts | 177 - .../generators/runtime/copyRuntime.test.ts | 100 - src/cmd/generators/runtime/copyRuntime.ts | 121 - src/cmd/generators/runtime/index.ts | 15 - src/cmd/generators/runtime/indexFile.ts | 46 - src/cmd/generators/runtime/meta.test.ts | 17 - src/cmd/index.ts | 2 - src/cmd/main.ts | 123 - src/cmd/testUtils.ts | 91 - src/cmd/types.ts | 19 - src/common/__mocks__/config.invalid.mock | 6 - src/common/tests.ts | 17 - src/common/types.ts | 16 - src/preprocess/index.ts | 53 - src/runtime/cache/index.ts | 12 - src/runtime/inline/index.ts | 4 - src/runtime/inline/mutation.ts | 15 - src/runtime/inline/query.ts | 28 - src/runtime/inline/subscription.ts | 18 - src/runtime/lib/HoudiniRTError.ts | 29 - src/runtime/lib/context.ts | 5 - src/runtime/lib/network.ts | 463 - src/vite/plugin.ts | 82 - src/vite/tests.ts | 195 - tsconfig.json | 31 +- tsconfig.root.json | 10 - tsconfig.runtime.cjs.json | 11 - tsconfig.runtime.esm.json | 22 - turbo.json | 17 + typeModule.js | 19 - vite.config.ts | 8 + vite.d.ts | 10 - vitest.setup.ts | 70 +- 418 files changed, 17773 insertions(+), 23608 deletions(-) create mode 100644 .changeset/proud-hairs-trade.md create mode 100644 .changeset/wild-coats-hang.md delete mode 100644 .npmignore create mode 100644 .npmrc rename {integration => e2e/sveltekit}/.eslintrc.cjs (100%) rename {integration => e2e/sveltekit}/.gitignore (100%) rename {integration => e2e/sveltekit}/.prettierrc (100%) create mode 100644 e2e/sveltekit/README.md rename {integration => e2e/sveltekit}/api/graphql.mjs (100%) rename {integration => e2e/sveltekit}/api/schema-hello.graphql (100%) rename {integration => e2e/sveltekit}/api/schema.graphql (100%) rename {integration => e2e/sveltekit}/api/server.mjs (100%) rename {integration => e2e/sveltekit}/houdini.config.js (77%) rename {integration => e2e/sveltekit}/package.json (82%) rename {integration => e2e/sveltekit}/playwright.config.ts (86%) rename {integration => e2e/sveltekit}/src/app.d.ts (100%) rename {integration => e2e/sveltekit}/src/app.html (100%) rename {integration => e2e/sveltekit}/src/hooks.server.ts (64%) rename {integration => e2e/sveltekit}/src/lib/QueryComponent.svelte (100%) rename {integration => e2e/sveltekit}/src/lib/QueryExt.svelte (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/houdiniClient.ts (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/FRAG.UserInfo.gql (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/MUTATION.AddUser.gql (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/MUTATION.EnumMutation.gql (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/MUTATION.UpdateUser.gql (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/MUTATION.UpdateUserSubUnsub.gql (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/QUERY.Hello.gql (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/QUERY.MultiUser.gql (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/QUERY.User.gql (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/QUERY.UsersList.gql (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/QUERY.UsersListSubUnsub.gql (100%) rename {integration => e2e/sveltekit}/src/lib/graphql/operations/QUERY.usersListComp.gql (100%) rename {integration => e2e/sveltekit}/src/lib/utils/routes.ts (98%) rename {integration => e2e/sveltekit}/src/lib/utils/testsHelper.ts (100%) rename {integration => e2e/sveltekit}/src/routes/+error.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/+layout.svelte (89%) rename {integration => e2e/sveltekit}/src/routes/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/index/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/layouts/+layout.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/layouts/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/layouts/layout/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/layouts/page2/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/fragment/backwards-cursor/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/fragment/backwards-cursor/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/fragment/forward-cursor/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/fragment/forward-cursor/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/fragment/offset/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/fragment/offset/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/query/backwards-cursor/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/query/backwards-cursor/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/query/forward-cursor/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/query/forward-cursor/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/query/offset-variable/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/query/offset-variable/+page.ts (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/query/offset-variable/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/query/offset/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/pagination/query/offset/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/+layout.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/+layout.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/fragment/update/+page.js (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/fragment/update/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/fragment/update/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/inlineAndGlobal/+page.js (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/inlineAndGlobal/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/inlineAndGlobal/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/list/+page.js (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/list/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/list/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/pageQuery-session/+page.gql (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/pageQuery-session/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/pageQuery-session/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/pageQuery/+page.gql (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/pageQuery/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/pageQuery/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/single/+page.js (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/single/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/load/single/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/afterLoad/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/afterLoad/+page.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/afterLoad/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/beforeLoad/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/beforeLoad/+page.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/beforeLoad/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/component/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/component/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/layout/+layout.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/layout/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/layout/layout/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/multiple/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/multiple/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/onError/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/onError/+page.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/onError/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/scalars/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/scalars/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/simple/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/simple/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/variable-[id]/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/variable-[id]/+page.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/variable-[id]/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/variables-error/+page.js (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/variables-error/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/plugin/query/variables-error/spec.ts (100%) create mode 100644 e2e/sveltekit/src/routes/query-param/+error.svelte create mode 100644 e2e/sveltekit/src/routes/query-param/+page.server.ts create mode 100644 e2e/sveltekit/src/routes/query-param/Loading.svelte create mode 100644 e2e/sveltekit/src/routes/query-param/UserName.svelte create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.gql create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.svelte create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.ts create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/+page.server.ts create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.gql create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.svelte create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.ts create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.gql create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.svelte create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.ts create mode 100644 e2e/sveltekit/src/routes/query-param/user-[userId]/spec.ts rename {integration => e2e/sveltekit}/src/routes/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/endpoint-query/+page.server.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/endpoint-query/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/endpoint-query/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/fragment-null/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/fragment-null/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/metadata/+page.svelte (88%) rename {integration => e2e/sveltekit}/src/routes/stores/metadata/spec.ts (89%) rename {integration => e2e/sveltekit}/src/routes/stores/mutation-enums/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/mutation-enums/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/mutation-scalars/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/mutation-scalars/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/mutation-update/+page.svelte (94%) rename {integration => e2e/sveltekit}/src/routes/stores/mutation-update/+page.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/mutation-update/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/mutation/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/mutation/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/network-one-store-multivariables/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/network-one-store-multivariables/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/network/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/network/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/pagination/query/StoreForwardCursorPaginationQuery.gql (100%) rename {integration => e2e/sveltekit}/src/routes/stores/pagination/query/forward-cursor/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/pagination/query/forward-cursor/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/partial/partial/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/partial/partial_List.gql (100%) rename {integration => e2e/sveltekit}/src/routes/stores/partial/partial_List/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/partial/partial_List/+page.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/partial/partial_[userId].gql (100%) rename {integration => e2e/sveltekit}/src/routes/stores/partial/partial_[userId]/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/partial/partial_[userId]/+page.ts (88%) rename {integration => e2e/sveltekit}/src/routes/stores/partial/partial_[userId]_Light.gql (100%) rename {integration => e2e/sveltekit}/src/routes/stores/partial/partial_[userId]_Light/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/partial/partial_[userId]_Light/+page.ts (89%) rename {integration => e2e/sveltekit}/src/routes/stores/prefetch-[userId]/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/prefetch-[userId]/+page.ts (88%) rename {integration => e2e/sveltekit}/src/routes/stores/prefetch-[userId]/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/session/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/session/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/ssr-[userId]/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/ssr-[userId]/+page.ts (90%) rename {integration => e2e/sveltekit}/src/routes/stores/ssr-[userId]/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/ssr-one-store-multivariables/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/ssr-one-store-multivariables/+page.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/ssr-one-store-multivariables/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/ssr/+page.svelte (99%) create mode 100644 e2e/sveltekit/src/routes/stores/ssr/+page.ts rename {integration => e2e/sveltekit}/src/routes/stores/ssr/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/subunsub-list/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/subunsub-list/spec.ts (100%) rename {integration => e2e/sveltekit}/src/routes/stores/subunsub-mutation/+page.svelte (100%) rename {integration => e2e/sveltekit}/src/routes/stores/withComp/+page.svelte (100%) rename {integration => e2e/sveltekit}/static/favicon.png (100%) rename {integration => e2e/sveltekit}/svelte.config.js (100%) rename {integration => e2e/sveltekit}/tsconfig.json (100%) rename {integration => e2e/sveltekit}/vite.config.js (100%) delete mode 100644 example/src/routes/+layout.js delete mode 100644 example/src/routes/addItem/+page.svelte create mode 100644 houdini.d.ts delete mode 100644 integration/README.md delete mode 100644 integration/src/routes/stores/ssr/+page.ts create mode 100644 packages/_scripts/build.js create mode 100755 packages/_scripts/main.js create mode 100644 packages/_scripts/package.json create mode 100644 packages/_scripts/typedefs.js create mode 100644 packages/houdini-svelte/package.json rename {src/cmd/generators/runtime => packages/houdini-svelte/src/plugin/codegen}/adapter.ts (68%) create mode 100644 packages/houdini-svelte/src/plugin/codegen/index.ts create mode 100644 packages/houdini-svelte/src/plugin/codegen/kit/index.ts rename {src/cmd/generators => packages/houdini-svelte/src/plugin/codegen}/kit/kit.test.ts (64%) rename {src/cmd/generators => packages/houdini-svelte/src/plugin/codegen}/stores/fragment.ts (73%) rename {src/cmd/generators => packages/houdini-svelte/src/plugin/codegen}/stores/index.ts (56%) rename {src/cmd/generators => packages/houdini-svelte/src/plugin/codegen}/stores/mutation.ts (63%) rename {src/cmd/generators => packages/houdini-svelte/src/plugin/codegen}/stores/query.test.ts (71%) rename {src/cmd/generators => packages/houdini-svelte/src/plugin/codegen}/stores/query.ts (76%) rename {src/cmd/generators => packages/houdini-svelte/src/plugin/codegen}/stores/subscription.ts (59%) rename src/common/parse.test.ts => packages/houdini-svelte/src/plugin/extract.test.ts (99%) rename src/common/parse.ts => packages/houdini-svelte/src/plugin/extract.ts (74%) rename {src/common => packages/houdini-svelte/src/plugin}/extractLoadFunction.test.ts (92%) rename {src/common => packages/houdini-svelte/src/plugin}/extractLoadFunction.ts (89%) rename {src/vite => packages/houdini-svelte/src/plugin}/fsPatch.ts (68%) create mode 100644 packages/houdini-svelte/src/plugin/imports.ts create mode 100644 packages/houdini-svelte/src/plugin/index.ts create mode 100644 packages/houdini-svelte/src/plugin/kit.ts rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/index.ts (76%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/kit/index.ts (53%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/kit/init.test.ts (61%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/kit/init.ts (68%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/kit/load.test.ts (76%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/kit/load.ts (83%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/kit/session.test.ts (81%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/kit/session.ts (87%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/query.test.ts (79%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/query.ts (87%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/reactive.ts (92%) rename {src/vite => packages/houdini-svelte/src/plugin}/transforms/tags.ts (50%) create mode 100644 packages/houdini-svelte/src/plugin/transforms/types.ts rename src/cmd/validators/forbiddenNames.test.ts => packages/houdini-svelte/src/plugin/validate.test.ts (76%) rename src/cmd/validators/forbiddenNames.ts => packages/houdini-svelte/src/plugin/validate.ts (50%) create mode 100644 packages/houdini-svelte/src/preprocess/index.ts rename {src => packages/houdini-svelte/src}/runtime/adapter.ts (86%) rename src/runtime/inline/fragment.ts => packages/houdini-svelte/src/runtime/fragments.ts (82%) rename {src/runtime/lib => packages/houdini-svelte/src/runtime}/index.ts (90%) create mode 100644 packages/houdini-svelte/src/runtime/network.ts create mode 100644 packages/houdini-svelte/src/runtime/session.ts rename {src => packages/houdini-svelte/src}/runtime/stores/fragment.ts (97%) rename {src => packages/houdini-svelte/src}/runtime/stores/index.ts (100%) rename {src => packages/houdini-svelte/src}/runtime/stores/mutation.ts (91%) rename {src => packages/houdini-svelte/src}/runtime/stores/pagination/cursor.ts (91%) rename {src => packages/houdini-svelte/src}/runtime/stores/pagination/fetch.ts (56%) rename {src => packages/houdini-svelte/src}/runtime/stores/pagination/fragment.ts (95%) rename {src => packages/houdini-svelte/src}/runtime/stores/pagination/index.ts (100%) rename {src => packages/houdini-svelte/src}/runtime/stores/pagination/offset.ts (88%) rename {src => packages/houdini-svelte/src}/runtime/stores/pagination/pageInfo.test.ts (100%) rename {src => packages/houdini-svelte/src}/runtime/stores/pagination/pageInfo.ts (91%) rename {src => packages/houdini-svelte/src}/runtime/stores/pagination/query.ts (93%) rename {src => packages/houdini-svelte/src}/runtime/stores/query.ts (92%) rename {src => packages/houdini-svelte/src}/runtime/stores/store.ts (54%) rename {src => packages/houdini-svelte/src}/runtime/stores/subscription.ts (90%) create mode 100644 packages/houdini-svelte/src/runtime/types.ts create mode 100644 packages/houdini-svelte/src/test/index.ts rename CHANGELOG.md => packages/houdini/CHANGELOG.md (100%) create mode 100644 packages/houdini/package.json create mode 100644 packages/houdini/src/cmd/generate.ts create mode 100755 packages/houdini/src/cmd/index.ts rename {src => packages/houdini/src}/cmd/init.ts (94%) rename {src => packages/houdini/src}/cmd/pullSchema.ts (92%) create mode 100644 packages/houdini/src/codegen/generators/artifacts/artifacts.test.ts rename {src/cmd => packages/houdini/src/codegen}/generators/artifacts/fieldKey.ts (98%) rename {src/cmd => packages/houdini/src/codegen}/generators/artifacts/index.ts (96%) rename {src/cmd => packages/houdini/src/codegen}/generators/artifacts/indexFile.ts (78%) rename {src/cmd => packages/houdini/src/codegen}/generators/artifacts/inputs.ts (89%) rename {src/cmd => packages/houdini/src/codegen}/generators/artifacts/operations.ts (98%) create mode 100644 packages/houdini/src/codegen/generators/artifacts/pagination.test.ts create mode 100644 packages/houdini/src/codegen/generators/artifacts/policy.test.ts rename {src/cmd => packages/houdini/src/codegen}/generators/artifacts/selection.ts (96%) rename {src/cmd => packages/houdini/src/codegen}/generators/artifacts/utils.test.ts (100%) rename {src/cmd => packages/houdini/src/codegen}/generators/artifacts/utils.ts (96%) rename {src/cmd => packages/houdini/src/codegen}/generators/definitions/enums.test.ts (72%) rename {src/cmd => packages/houdini/src/codegen}/generators/definitions/enums.ts (82%) rename {src/cmd => packages/houdini/src/codegen}/generators/definitions/index.ts (54%) create mode 100644 packages/houdini/src/codegen/generators/definitions/schema.test.ts rename {src/cmd => packages/houdini/src/codegen}/generators/index.ts (76%) create mode 100644 packages/houdini/src/codegen/generators/indexFile/index.ts rename {src/cmd/generators/artifacts => packages/houdini/src/codegen/generators/indexFile}/indexFile.test.ts (85%) rename {src/cmd => packages/houdini/src/codegen}/generators/persistedQueries/index.ts (88%) rename {src/cmd => packages/houdini/src/codegen}/generators/persistedQueries/persistedQuery.test.ts (53%) rename src/cmd/generators/runtime/indexFile.test.ts => packages/houdini/src/codegen/generators/runtime/index.test.ts (86%) create mode 100644 packages/houdini/src/codegen/generators/runtime/index.ts create mode 100644 packages/houdini/src/codegen/generators/runtime/runtime.test.ts rename {src/cmd => packages/houdini/src/codegen}/generators/typescript/addReferencedInputTypes.ts (89%) rename {src/cmd => packages/houdini/src/codegen}/generators/typescript/index.ts (90%) rename {src/cmd => packages/houdini/src/codegen}/generators/typescript/inlineType.ts (97%) rename {src/cmd => packages/houdini/src/codegen}/generators/typescript/typeReference.ts (92%) rename {src/cmd => packages/houdini/src/codegen}/generators/typescript/types.ts (85%) rename {src/cmd => packages/houdini/src/codegen}/generators/typescript/typescript.test.ts (78%) rename src/cmd/generate.ts => packages/houdini/src/codegen/index.ts (66%) rename {src/cmd => packages/houdini/src/codegen}/transforms/addID.test.ts (91%) rename {src/cmd => packages/houdini/src/codegen}/transforms/addID.ts (90%) rename {src/cmd => packages/houdini/src/codegen}/transforms/composeQueries.test.ts (80%) rename {src/cmd => packages/houdini/src/codegen}/transforms/composeQueries.ts (97%) rename {src/cmd => packages/houdini/src/codegen}/transforms/fragmentVariables.test.ts (88%) rename {src/cmd => packages/houdini/src/codegen}/transforms/fragmentVariables.ts (98%) rename {src/cmd => packages/houdini/src/codegen}/transforms/index.ts (100%) rename {src/cmd => packages/houdini/src/codegen}/transforms/list.ts (93%) rename {src/cmd => packages/houdini/src/codegen}/transforms/lists.test.ts (95%) rename {src/cmd => packages/houdini/src/codegen}/transforms/paginate.test.ts (60%) rename {src/cmd => packages/houdini/src/codegen}/transforms/paginate.ts (87%) rename {src/cmd => packages/houdini/src/codegen}/transforms/schema.test.ts (91%) rename {src/cmd => packages/houdini/src/codegen}/transforms/schema.ts (94%) rename {src/cmd => packages/houdini/src/codegen}/transforms/typename.test.ts (94%) rename {src/cmd => packages/houdini/src/codegen}/transforms/typename.ts (89%) rename {src/cmd => packages/houdini/src/codegen}/utils/commonjs.ts (100%) rename {src/cmd => packages/houdini/src/codegen}/utils/flattenSelections.ts (98%) rename {src/cmd => packages/houdini/src/codegen}/utils/graphql.test.ts (94%) rename {src/cmd => packages/houdini/src/codegen}/utils/graphql.ts (89%) rename {src/cmd => packages/houdini/src/codegen}/utils/index.ts (81%) rename {src/cmd => packages/houdini/src/codegen}/utils/moduleExport.ts (88%) rename {src/cmd => packages/houdini/src/codegen}/utils/murmur.ts (96%) rename {src/cmd => packages/houdini/src/codegen}/validators/index.ts (72%) rename {src/cmd => packages/houdini/src/codegen}/validators/noIDAlias.test.ts (84%) rename {src/cmd => packages/houdini/src/codegen}/validators/noIDAlias.ts (87%) create mode 100644 packages/houdini/src/codegen/validators/plugins.ts rename {src/cmd => packages/houdini/src/codegen}/validators/typeCheck.test.ts (97%) rename {src/cmd => packages/houdini/src/codegen}/validators/typeCheck.ts (97%) rename {src/cmd => packages/houdini/src/codegen}/validators/uniqueNames.test.ts (81%) rename {src/cmd => packages/houdini/src/codegen}/validators/uniqueNames.ts (89%) rename {src/cmd/utils => packages/houdini/src/lib}/cleanupFiles.ts (67%) rename {src/common => packages/houdini/src/lib}/config.test.ts (100%) rename {src/common => packages/houdini/src/lib}/config.ts (64%) create mode 100644 packages/houdini/src/lib/constants.ts rename {src/common => packages/houdini/src/lib}/error.ts (100%) rename {src/common => packages/houdini/src/lib}/fs.ts (57%) rename {src/common => packages/houdini/src/lib}/graphql.test.ts (100%) rename {src/common => packages/houdini/src/lib}/graphql.ts (100%) rename {src/common => packages/houdini/src/lib}/imports.ts (76%) rename {src/common => packages/houdini/src/lib}/index.ts (64%) rename {src/cmd/utils => packages/houdini/src/lib}/introspection.ts (86%) create mode 100644 packages/houdini/src/lib/parse.ts rename {src/common => packages/houdini/src/lib}/pipeline.ts (100%) create mode 100644 packages/houdini/src/lib/types.ts rename {src/common => packages/houdini/src/lib}/walk.ts (93%) rename {src => packages/houdini/src}/runtime/cache/cache.ts (97%) rename {src => packages/houdini/src}/runtime/cache/gc.ts (92%) create mode 100644 packages/houdini/src/runtime/cache/index.ts rename {src => packages/houdini/src}/runtime/cache/lists.ts (100%) rename {src => packages/houdini/src}/runtime/cache/storage.ts (99%) rename {src => packages/houdini/src}/runtime/cache/stuff.ts (100%) rename {src => packages/houdini/src}/runtime/cache/subscription.ts (100%) rename {src => packages/houdini/src}/runtime/cache/tests/availability.test.ts (99%) rename {src => packages/houdini/src}/runtime/cache/tests/gc.test.ts (99%) rename {src => packages/houdini/src}/runtime/cache/tests/keys.test.ts (100%) rename {src => packages/houdini/src}/runtime/cache/tests/list.test.ts (99%) rename {src => packages/houdini/src}/runtime/cache/tests/readwrite.test.ts (99%) rename {src => packages/houdini/src}/runtime/cache/tests/scalars.test.ts (98%) rename {src => packages/houdini/src}/runtime/cache/tests/storage.test.ts (100%) rename {src => packages/houdini/src}/runtime/cache/tests/subscriptions.test.ts (99%) rename {src => packages/houdini/src}/runtime/index.ts (91%) rename {src => packages/houdini/src}/runtime/lib/config.ts (82%) rename {src => packages/houdini/src}/runtime/lib/constants.ts (89%) rename {src => packages/houdini/src}/runtime/lib/deepEquals.ts (100%) rename {src => packages/houdini/src}/runtime/lib/errors.ts (100%) create mode 100644 packages/houdini/src/runtime/lib/index.ts rename {src => packages/houdini/src}/runtime/lib/log.ts (98%) create mode 100644 packages/houdini/src/runtime/lib/network.ts rename {src => packages/houdini/src}/runtime/lib/scalars.test.ts (87%) rename {src => packages/houdini/src}/runtime/lib/scalars.ts (98%) rename {src => packages/houdini/src}/runtime/lib/types.ts (75%) rename src/runtime/lib/test.ts => packages/houdini/src/test/index.ts (55%) rename {src => packages/houdini/src}/vite/ast.ts (99%) create mode 100644 packages/houdini/src/vite/houdini.ts rename {src => packages/houdini/src}/vite/imports.ts (76%) rename {src => packages/houdini/src}/vite/index.ts (56%) rename {src => packages/houdini/src}/vite/schema.ts (81%) delete mode 100644 rollup.config.js delete mode 100644 runtimeMeta.js delete mode 100644 src/cmd/generators/artifacts/artifacts.test.ts delete mode 100644 src/cmd/generators/artifacts/pagination.test.ts delete mode 100644 src/cmd/generators/artifacts/policy.test.ts delete mode 100644 src/cmd/generators/definitions/schema.test.ts delete mode 100644 src/cmd/generators/kit/index.ts delete mode 100644 src/cmd/generators/runtime/copyRuntime.test.ts delete mode 100644 src/cmd/generators/runtime/copyRuntime.ts delete mode 100644 src/cmd/generators/runtime/index.ts delete mode 100644 src/cmd/generators/runtime/indexFile.ts delete mode 100644 src/cmd/generators/runtime/meta.test.ts delete mode 100644 src/cmd/index.ts delete mode 100755 src/cmd/main.ts delete mode 100644 src/cmd/testUtils.ts delete mode 100644 src/cmd/types.ts delete mode 100644 src/common/__mocks__/config.invalid.mock delete mode 100644 src/common/tests.ts delete mode 100644 src/common/types.ts delete mode 100644 src/preprocess/index.ts delete mode 100644 src/runtime/cache/index.ts delete mode 100644 src/runtime/inline/index.ts delete mode 100644 src/runtime/inline/mutation.ts delete mode 100644 src/runtime/inline/query.ts delete mode 100644 src/runtime/inline/subscription.ts delete mode 100644 src/runtime/lib/HoudiniRTError.ts delete mode 100644 src/runtime/lib/context.ts delete mode 100644 src/runtime/lib/network.ts delete mode 100644 src/vite/plugin.ts delete mode 100644 src/vite/tests.ts delete mode 100644 tsconfig.root.json delete mode 100644 tsconfig.runtime.cjs.json delete mode 100644 tsconfig.runtime.esm.json create mode 100644 turbo.json delete mode 100644 typeModule.js delete mode 100644 vite.d.ts diff --git a/.changeset/proud-hairs-trade.md b/.changeset/proud-hairs-trade.md new file mode 100644 index 0000000000..86461d5351 --- /dev/null +++ b/.changeset/proud-hairs-trade.md @@ -0,0 +1,5 @@ +--- +'houdini-svelte': patch +--- + +Adding layout.gql special file diff --git a/.changeset/wild-coats-hang.md b/.changeset/wild-coats-hang.md new file mode 100644 index 0000000000..3ebaae50be --- /dev/null +++ b/.changeset/wild-coats-hang.md @@ -0,0 +1,6 @@ +--- +'houdini': minor +'houdini-svelte': minor +--- + +Split houdini into two packages: `houdini` and `houdini-svelte` diff --git a/.eslintrc.cjs b/.eslintrc.cjs index 30de907379..9671b107e1 100644 --- a/.eslintrc.cjs +++ b/.eslintrc.cjs @@ -2,6 +2,9 @@ module.exports = { root: true, extends: '@theguild', rules: { + '@typescript-eslint/triple-slash-reference': 'off', + '@typescript-eslint/no-empty-interface': 'off', + '@typescript-eslint/no-namespace': 'off', '@typescript-eslint/no-unused-vars': 'off', '@typescript-eslint/ban-ts-comment': 'off', '@typescript-eslint/no-non-null-assertion': 'off', @@ -28,7 +31,7 @@ module.exports = { 'object-shorthand': 'off', // 'no-console': ['error', { allow: ['info', 'warn', 'error', 'time', 'timeEnd'] }], }, - ignorePatterns: ['integration', 'example', 'site'], + ignorePatterns: ['e2e', 'example', 'site'], parserOptions: { sourceType: 'module', ecmaVersion: 2020, diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index ef1833b65c..c9b4a69b6a 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -81,13 +81,13 @@ jobs: run: pnpm install - name: Build packages - run: pnpm run build + run: pnpm run compile - name: Tests run: pnpm run tests - integration: - name: Integration Tests + e2e_sveltekit: + name: End-to-End Tests runs-on: ubuntu-latest steps: @@ -132,17 +132,14 @@ jobs: key: cache-playwright-linux-1.25.0 - name: Build packages - run: pnpm run build + run: pnpm run compile - name: Install Playwright if: steps.playwright-cache.outputs.cache-hit != 'true' run: npx playwright install --with-deps - - name: SvelteKit Sync - run: cd integration && npx svelte-kit sync - - - name: Integration Tests - run: pnpm --filter integration tests + - name: End-to-End Tests sveltekit + run: pnpm run --filter sveltekit build && pnpm --filter sveltekit tests env: RECORD_REPLAY_TEST_RUN_ID: ${{ env.GITHUB_SHA }} @@ -153,8 +150,8 @@ jobs: api-key: ${{ secrets.RECORD_REPLAY_API_KEY }} filter: ${{ 'function($v) { $v.metadata.test.result = "failed" and $v.status = "onDisk" }' }} - integration_linter: - name: Integration Linter + e2e_sveltekit_linter: + name: End-to-End Linter runs-on: ubuntu-latest steps: @@ -193,15 +190,12 @@ jobs: - name: Build Package run: pnpm run build - - name: SvelteKit Sync - run: cd integration && npx svelte-kit sync - - name: Build kit assets - run: pnpm --filter integration run build + run: pnpm --filter sveltekit run build # needs to run after build & houdini generate - - name: Integration lint - run: pnpm --filter integration run lint + - name: End-to-End lint + run: pnpm --filter sveltekit run lint - - name: Integration check - run: pnpm --filter integration run check + - name: End-to-End check + run: pnpm --filter sveltekit run check diff --git a/.gitignore b/.gitignore index 88bc500c04..eae3e09687 100644 --- a/.gitignore +++ b/.gitignore @@ -1,8 +1,9 @@ node_modules + .DS_Store .vscode -build +packages/*/build bin .pnp.* @@ -12,4 +13,9 @@ example/.svelte-kit example/functions example/$houdini -/playground.js \ No newline at end of file +/playground.js + +.turbo +build/** +dist/** +.next/** diff --git a/.graphqlrc.yaml b/.graphqlrc.yaml index b4154f47fe..0a92465f7e 100644 --- a/.graphqlrc.yaml +++ b/.graphqlrc.yaml @@ -2,8 +2,8 @@ projects: default: # 👇 For vscode-graphql and intellisense schema: - - integration/api/*.graphql - - integration/$houdini/graphql/schema.graphql + - e2e/api/*.graphql + - e2e/$houdini/graphql/schema.graphql documents: - - integration/src/**/*.gql - - integration/$houdini/graphql/documents.gql + - e2e/src/**/*.gql + - e2e/$houdini/graphql/documents.gql diff --git a/.npmignore b/.npmignore deleted file mode 100644 index e8a4a845d0..0000000000 --- a/.npmignore +++ /dev/null @@ -1,5 +0,0 @@ -integration/ -example/ -.changeset/ -.github/ -*.test.ts \ No newline at end of file diff --git a/.npmrc b/.npmrc new file mode 100644 index 0000000000..3bfab73a91 --- /dev/null +++ b/.npmrc @@ -0,0 +1,3 @@ +auto-install-peers=true +strict-peer-dependencies=false + diff --git a/.prettierignore b/.prettierignore index 279463882c..d37871f4fb 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,3 +1,4 @@ **/build/** README.md -.github/** \ No newline at end of file +.github/** +packages/*/package.json \ No newline at end of file diff --git a/integration/.eslintrc.cjs b/e2e/sveltekit/.eslintrc.cjs similarity index 100% rename from integration/.eslintrc.cjs rename to e2e/sveltekit/.eslintrc.cjs diff --git a/integration/.gitignore b/e2e/sveltekit/.gitignore similarity index 100% rename from integration/.gitignore rename to e2e/sveltekit/.gitignore diff --git a/integration/.prettierrc b/e2e/sveltekit/.prettierrc similarity index 100% rename from integration/.prettierrc rename to e2e/sveltekit/.prettierrc diff --git a/e2e/sveltekit/README.md b/e2e/sveltekit/README.md new file mode 100644 index 0000000000..ae938034f3 --- /dev/null +++ b/e2e/sveltekit/README.md @@ -0,0 +1 @@ +# Houdini End-to-End diff --git a/integration/api/graphql.mjs b/e2e/sveltekit/api/graphql.mjs similarity index 100% rename from integration/api/graphql.mjs rename to e2e/sveltekit/api/graphql.mjs diff --git a/integration/api/schema-hello.graphql b/e2e/sveltekit/api/schema-hello.graphql similarity index 100% rename from integration/api/schema-hello.graphql rename to e2e/sveltekit/api/schema-hello.graphql diff --git a/integration/api/schema.graphql b/e2e/sveltekit/api/schema.graphql similarity index 100% rename from integration/api/schema.graphql rename to e2e/sveltekit/api/schema.graphql diff --git a/integration/api/server.mjs b/e2e/sveltekit/api/server.mjs similarity index 100% rename from integration/api/server.mjs rename to e2e/sveltekit/api/server.mjs diff --git a/integration/houdini.config.js b/e2e/sveltekit/houdini.config.js similarity index 77% rename from integration/houdini.config.js rename to e2e/sveltekit/houdini.config.js index 59042bcdab..3f9225341c 100644 --- a/integration/houdini.config.js +++ b/e2e/sveltekit/houdini.config.js @@ -1,6 +1,7 @@ +/// + /** @type {import('houdini').ConfigFile} */ const config = { - client: './src/lib/graphql/houdiniClient', schemaPath: './api/*.graphql', defaultCachePolicy: 'CacheOrNetwork', defaultPartial: true, @@ -16,6 +17,11 @@ const config = { return val.getTime(); } } + }, + plugins: { + 'houdini-svelte': { + client: './src/lib/graphql/houdiniClient' + } } }; diff --git a/integration/package.json b/e2e/sveltekit/package.json similarity index 82% rename from integration/package.json rename to e2e/sveltekit/package.json index 339c833364..28866cd889 100644 --- a/integration/package.json +++ b/e2e/sveltekit/package.json @@ -1,9 +1,10 @@ { - "name": "integration", + "name": "sveltekit", "version": "0.0.1", "private": true, + "type": "module", "scripts": { - "web": "cross-env TZ=utc vite dev", + "web": "cross-env TZ=utc vite dev --host 0.0.0.0", "api": "cross-env TZ=utc node api/server.mjs", "dev": "concurrently \"pnpm run web\" \"pnpm run api\" -n \"web,api\" -c \"green,magenta\"", "build": "vite build", @@ -11,8 +12,9 @@ "previewWeb": "cross-env TZ=utc vite preview --port 3007", "preview": "concurrently \"pnpm run previewWeb\" \"pnpm run api\" -n \"web,api\" -c \"green,magenta\"", "tests": "playwright test ", + "test": "npm run tests", "check": "svelte-check --tsconfig ./tsconfig.json", - "check:watch": "svelte-check --tsconfig ./tsconfig.json --watch", + "check:watch": "pnpm run check -- --watch", "lint": "prettier --ignore-path .gitignore --check --plugin-search-dir=. . && eslint --ignore-path .gitignore .", "format": "prettier --ignore-path .gitignore --write --plugin-search-dir=. ." }, @@ -20,7 +22,7 @@ "@playwright/test": "1.25.0", "@replayio/playwright": "0.2.23", "@sveltejs/adapter-auto": "1.0.0-next.66", - "@sveltejs/kit": "1.0.0-next.481", + "@sveltejs/kit": "1.0.0-next.510", "@typescript-eslint/eslint-plugin": "^5.10.1", "@typescript-eslint/parser": "^5.10.1", "concurrently": "7.1.0", @@ -30,6 +32,7 @@ "eslint-plugin-svelte3": "^4.0.0", "graphql": "^15.5.0", "houdini": "workspace:^", + "houdini-svelte": "workspace:^", "prettier": "^2.5.1", "prettier-plugin-svelte": "^2.5.0", "svelte": "^3.47.0", @@ -40,12 +43,12 @@ "vite": "^3.1.0" }, "dependencies": { - "@graphql-yoga/node": "^2.8.0", + "@graphql-yoga/node": "^2.13.13", + "@kitql/helper": "^0.5.0", "graphql-relay": "^0.10.0", "graphql-tag": "^2.12.6", "graphql-ws": "^5.8.2", "mdsvex": "^0.10.5", "ws": "^8.8.1" - }, - "type": "module" + } } diff --git a/integration/playwright.config.ts b/e2e/sveltekit/playwright.config.ts similarity index 86% rename from integration/playwright.config.ts rename to e2e/sveltekit/playwright.config.ts index 8c221d77ab..8b9f7b4284 100644 --- a/integration/playwright.config.ts +++ b/e2e/sveltekit/playwright.config.ts @@ -7,13 +7,13 @@ const with_replayio = false; const use = with_replayio ? { // eslint-disable-next-line @typescript-eslint/no-explicit-any - ...(replayDevices['Replay Chromium'] as any), + ...replayDevices['Replay Chromium'], screenshot: 'only-on-failure' } : { screenshot: 'only-on-failure' }; // eslint-disable-next-line @typescript-eslint/no-explicit-any -const reporter: any[] = [['list']]; +const reporter = [['list']]; if (process.env.CI) { reporter.push(['html', { open: 'never' }]); reporter.push(['github']); @@ -22,7 +22,7 @@ if (with_replayio) { reporter.push(['@replayio/playwright/reporter']); } -const config: PlaywrightTestConfig = { +const config = { // retries: 2, workers: 5, reporter, diff --git a/integration/src/app.d.ts b/e2e/sveltekit/src/app.d.ts similarity index 100% rename from integration/src/app.d.ts rename to e2e/sveltekit/src/app.d.ts diff --git a/integration/src/app.html b/e2e/sveltekit/src/app.html similarity index 100% rename from integration/src/app.html rename to e2e/sveltekit/src/app.html diff --git a/integration/src/hooks.server.ts b/e2e/sveltekit/src/hooks.server.ts similarity index 64% rename from integration/src/hooks.server.ts rename to e2e/sveltekit/src/hooks.server.ts index 77f97f14d1..cd3199ba34 100644 --- a/integration/src/hooks.server.ts +++ b/e2e/sveltekit/src/hooks.server.ts @@ -1,9 +1,9 @@ -import houdini from './lib/graphql/houdiniClient'; +import { setSession } from '$houdini'; import type { Handle } from '@sveltejs/kit'; export const handle: Handle = async ({ event, resolve }) => { // set the session information for this event - houdini.setSession(event, { user: { token: '1234-Houdini-Token-5678' } }); + setSession(event, { user: { token: '1234-Houdini-Token-5678' } }); // pass the event onto the default handle return await resolve(event); diff --git a/integration/src/lib/QueryComponent.svelte b/e2e/sveltekit/src/lib/QueryComponent.svelte similarity index 100% rename from integration/src/lib/QueryComponent.svelte rename to e2e/sveltekit/src/lib/QueryComponent.svelte diff --git a/integration/src/lib/QueryExt.svelte b/e2e/sveltekit/src/lib/QueryExt.svelte similarity index 100% rename from integration/src/lib/QueryExt.svelte rename to e2e/sveltekit/src/lib/QueryExt.svelte diff --git a/integration/src/lib/graphql/houdiniClient.ts b/e2e/sveltekit/src/lib/graphql/houdiniClient.ts similarity index 100% rename from integration/src/lib/graphql/houdiniClient.ts rename to e2e/sveltekit/src/lib/graphql/houdiniClient.ts diff --git a/integration/src/lib/graphql/operations/FRAG.UserInfo.gql b/e2e/sveltekit/src/lib/graphql/operations/FRAG.UserInfo.gql similarity index 100% rename from integration/src/lib/graphql/operations/FRAG.UserInfo.gql rename to e2e/sveltekit/src/lib/graphql/operations/FRAG.UserInfo.gql diff --git a/integration/src/lib/graphql/operations/MUTATION.AddUser.gql b/e2e/sveltekit/src/lib/graphql/operations/MUTATION.AddUser.gql similarity index 100% rename from integration/src/lib/graphql/operations/MUTATION.AddUser.gql rename to e2e/sveltekit/src/lib/graphql/operations/MUTATION.AddUser.gql diff --git a/integration/src/lib/graphql/operations/MUTATION.EnumMutation.gql b/e2e/sveltekit/src/lib/graphql/operations/MUTATION.EnumMutation.gql similarity index 100% rename from integration/src/lib/graphql/operations/MUTATION.EnumMutation.gql rename to e2e/sveltekit/src/lib/graphql/operations/MUTATION.EnumMutation.gql diff --git a/integration/src/lib/graphql/operations/MUTATION.UpdateUser.gql b/e2e/sveltekit/src/lib/graphql/operations/MUTATION.UpdateUser.gql similarity index 100% rename from integration/src/lib/graphql/operations/MUTATION.UpdateUser.gql rename to e2e/sveltekit/src/lib/graphql/operations/MUTATION.UpdateUser.gql diff --git a/integration/src/lib/graphql/operations/MUTATION.UpdateUserSubUnsub.gql b/e2e/sveltekit/src/lib/graphql/operations/MUTATION.UpdateUserSubUnsub.gql similarity index 100% rename from integration/src/lib/graphql/operations/MUTATION.UpdateUserSubUnsub.gql rename to e2e/sveltekit/src/lib/graphql/operations/MUTATION.UpdateUserSubUnsub.gql diff --git a/integration/src/lib/graphql/operations/QUERY.Hello.gql b/e2e/sveltekit/src/lib/graphql/operations/QUERY.Hello.gql similarity index 100% rename from integration/src/lib/graphql/operations/QUERY.Hello.gql rename to e2e/sveltekit/src/lib/graphql/operations/QUERY.Hello.gql diff --git a/integration/src/lib/graphql/operations/QUERY.MultiUser.gql b/e2e/sveltekit/src/lib/graphql/operations/QUERY.MultiUser.gql similarity index 100% rename from integration/src/lib/graphql/operations/QUERY.MultiUser.gql rename to e2e/sveltekit/src/lib/graphql/operations/QUERY.MultiUser.gql diff --git a/integration/src/lib/graphql/operations/QUERY.User.gql b/e2e/sveltekit/src/lib/graphql/operations/QUERY.User.gql similarity index 100% rename from integration/src/lib/graphql/operations/QUERY.User.gql rename to e2e/sveltekit/src/lib/graphql/operations/QUERY.User.gql diff --git a/integration/src/lib/graphql/operations/QUERY.UsersList.gql b/e2e/sveltekit/src/lib/graphql/operations/QUERY.UsersList.gql similarity index 100% rename from integration/src/lib/graphql/operations/QUERY.UsersList.gql rename to e2e/sveltekit/src/lib/graphql/operations/QUERY.UsersList.gql diff --git a/integration/src/lib/graphql/operations/QUERY.UsersListSubUnsub.gql b/e2e/sveltekit/src/lib/graphql/operations/QUERY.UsersListSubUnsub.gql similarity index 100% rename from integration/src/lib/graphql/operations/QUERY.UsersListSubUnsub.gql rename to e2e/sveltekit/src/lib/graphql/operations/QUERY.UsersListSubUnsub.gql diff --git a/integration/src/lib/graphql/operations/QUERY.usersListComp.gql b/e2e/sveltekit/src/lib/graphql/operations/QUERY.usersListComp.gql similarity index 100% rename from integration/src/lib/graphql/operations/QUERY.usersListComp.gql rename to e2e/sveltekit/src/lib/graphql/operations/QUERY.usersListComp.gql diff --git a/integration/src/lib/utils/routes.ts b/e2e/sveltekit/src/lib/utils/routes.ts similarity index 98% rename from integration/src/lib/utils/routes.ts rename to e2e/sveltekit/src/lib/utils/routes.ts index 87ebf5ebab..518698bfe7 100644 --- a/integration/src/lib/utils/routes.ts +++ b/e2e/sveltekit/src/lib/utils/routes.ts @@ -2,6 +2,9 @@ export const routes = { Home: '/', GraphQL: 'http://localhost:4000/graphql', + // features + Query_param: '/query-param', + Stores_SSR: '/stores/ssr', Stores_Network: '/stores/network', Stores_SSR_UserId_2: '/stores/ssr-2', diff --git a/integration/src/lib/utils/testsHelper.ts b/e2e/sveltekit/src/lib/utils/testsHelper.ts similarity index 100% rename from integration/src/lib/utils/testsHelper.ts rename to e2e/sveltekit/src/lib/utils/testsHelper.ts diff --git a/integration/src/routes/+error.svelte b/e2e/sveltekit/src/routes/+error.svelte similarity index 100% rename from integration/src/routes/+error.svelte rename to e2e/sveltekit/src/routes/+error.svelte diff --git a/integration/src/routes/+layout.svelte b/e2e/sveltekit/src/routes/+layout.svelte similarity index 89% rename from integration/src/routes/+layout.svelte rename to e2e/sveltekit/src/routes/+layout.svelte index 63ebe6a81b..1911b7a976 100644 --- a/integration/src/routes/+layout.svelte +++ b/e2e/sveltekit/src/routes/+layout.svelte @@ -2,7 +2,7 @@ import { browser } from '$app/environment'; import { graphql } from '$houdini'; import cache from '$houdini/runtime/cache'; - import { routes } from '$lib/utils/routes'; + import { routes } from '$lib/utils/routes.js'; if (browser) { // @ts-ignore @@ -33,5 +33,5 @@
- {$info.data.session} + {$info.data?.session}
diff --git a/integration/src/routes/+page.svelte b/e2e/sveltekit/src/routes/+page.svelte similarity index 100% rename from integration/src/routes/+page.svelte rename to e2e/sveltekit/src/routes/+page.svelte diff --git a/integration/src/routes/index/spec.ts b/e2e/sveltekit/src/routes/index/spec.ts similarity index 100% rename from integration/src/routes/index/spec.ts rename to e2e/sveltekit/src/routes/index/spec.ts diff --git a/integration/src/routes/layouts/+layout.svelte b/e2e/sveltekit/src/routes/layouts/+layout.svelte similarity index 100% rename from integration/src/routes/layouts/+layout.svelte rename to e2e/sveltekit/src/routes/layouts/+layout.svelte diff --git a/integration/src/routes/layouts/+page.svelte b/e2e/sveltekit/src/routes/layouts/+page.svelte similarity index 100% rename from integration/src/routes/layouts/+page.svelte rename to e2e/sveltekit/src/routes/layouts/+page.svelte diff --git a/integration/src/routes/layouts/layout/spec.ts b/e2e/sveltekit/src/routes/layouts/layout/spec.ts similarity index 100% rename from integration/src/routes/layouts/layout/spec.ts rename to e2e/sveltekit/src/routes/layouts/layout/spec.ts diff --git a/integration/src/routes/layouts/page2/+page.svelte b/e2e/sveltekit/src/routes/layouts/page2/+page.svelte similarity index 100% rename from integration/src/routes/layouts/page2/+page.svelte rename to e2e/sveltekit/src/routes/layouts/page2/+page.svelte diff --git a/integration/src/routes/pagination/fragment/backwards-cursor/+page.svelte b/e2e/sveltekit/src/routes/pagination/fragment/backwards-cursor/+page.svelte similarity index 100% rename from integration/src/routes/pagination/fragment/backwards-cursor/+page.svelte rename to e2e/sveltekit/src/routes/pagination/fragment/backwards-cursor/+page.svelte diff --git a/integration/src/routes/pagination/fragment/backwards-cursor/spec.ts b/e2e/sveltekit/src/routes/pagination/fragment/backwards-cursor/spec.ts similarity index 100% rename from integration/src/routes/pagination/fragment/backwards-cursor/spec.ts rename to e2e/sveltekit/src/routes/pagination/fragment/backwards-cursor/spec.ts diff --git a/integration/src/routes/pagination/fragment/forward-cursor/+page.svelte b/e2e/sveltekit/src/routes/pagination/fragment/forward-cursor/+page.svelte similarity index 100% rename from integration/src/routes/pagination/fragment/forward-cursor/+page.svelte rename to e2e/sveltekit/src/routes/pagination/fragment/forward-cursor/+page.svelte diff --git a/integration/src/routes/pagination/fragment/forward-cursor/spec.ts b/e2e/sveltekit/src/routes/pagination/fragment/forward-cursor/spec.ts similarity index 100% rename from integration/src/routes/pagination/fragment/forward-cursor/spec.ts rename to e2e/sveltekit/src/routes/pagination/fragment/forward-cursor/spec.ts diff --git a/integration/src/routes/pagination/fragment/offset/+page.svelte b/e2e/sveltekit/src/routes/pagination/fragment/offset/+page.svelte similarity index 100% rename from integration/src/routes/pagination/fragment/offset/+page.svelte rename to e2e/sveltekit/src/routes/pagination/fragment/offset/+page.svelte diff --git a/integration/src/routes/pagination/fragment/offset/spec.ts b/e2e/sveltekit/src/routes/pagination/fragment/offset/spec.ts similarity index 100% rename from integration/src/routes/pagination/fragment/offset/spec.ts rename to e2e/sveltekit/src/routes/pagination/fragment/offset/spec.ts diff --git a/integration/src/routes/pagination/query/backwards-cursor/+page.svelte b/e2e/sveltekit/src/routes/pagination/query/backwards-cursor/+page.svelte similarity index 100% rename from integration/src/routes/pagination/query/backwards-cursor/+page.svelte rename to e2e/sveltekit/src/routes/pagination/query/backwards-cursor/+page.svelte diff --git a/integration/src/routes/pagination/query/backwards-cursor/spec.ts b/e2e/sveltekit/src/routes/pagination/query/backwards-cursor/spec.ts similarity index 100% rename from integration/src/routes/pagination/query/backwards-cursor/spec.ts rename to e2e/sveltekit/src/routes/pagination/query/backwards-cursor/spec.ts diff --git a/integration/src/routes/pagination/query/forward-cursor/+page.svelte b/e2e/sveltekit/src/routes/pagination/query/forward-cursor/+page.svelte similarity index 100% rename from integration/src/routes/pagination/query/forward-cursor/+page.svelte rename to e2e/sveltekit/src/routes/pagination/query/forward-cursor/+page.svelte diff --git a/integration/src/routes/pagination/query/forward-cursor/spec.ts b/e2e/sveltekit/src/routes/pagination/query/forward-cursor/spec.ts similarity index 100% rename from integration/src/routes/pagination/query/forward-cursor/spec.ts rename to e2e/sveltekit/src/routes/pagination/query/forward-cursor/spec.ts diff --git a/integration/src/routes/pagination/query/offset-variable/+page.svelte b/e2e/sveltekit/src/routes/pagination/query/offset-variable/+page.svelte similarity index 100% rename from integration/src/routes/pagination/query/offset-variable/+page.svelte rename to e2e/sveltekit/src/routes/pagination/query/offset-variable/+page.svelte diff --git a/integration/src/routes/pagination/query/offset-variable/+page.ts b/e2e/sveltekit/src/routes/pagination/query/offset-variable/+page.ts similarity index 100% rename from integration/src/routes/pagination/query/offset-variable/+page.ts rename to e2e/sveltekit/src/routes/pagination/query/offset-variable/+page.ts diff --git a/integration/src/routes/pagination/query/offset-variable/spec.ts b/e2e/sveltekit/src/routes/pagination/query/offset-variable/spec.ts similarity index 100% rename from integration/src/routes/pagination/query/offset-variable/spec.ts rename to e2e/sveltekit/src/routes/pagination/query/offset-variable/spec.ts diff --git a/integration/src/routes/pagination/query/offset/+page.svelte b/e2e/sveltekit/src/routes/pagination/query/offset/+page.svelte similarity index 100% rename from integration/src/routes/pagination/query/offset/+page.svelte rename to e2e/sveltekit/src/routes/pagination/query/offset/+page.svelte diff --git a/integration/src/routes/pagination/query/offset/spec.ts b/e2e/sveltekit/src/routes/pagination/query/offset/spec.ts similarity index 100% rename from integration/src/routes/pagination/query/offset/spec.ts rename to e2e/sveltekit/src/routes/pagination/query/offset/spec.ts diff --git a/integration/src/routes/plugin/+layout.svelte b/e2e/sveltekit/src/routes/plugin/+layout.svelte similarity index 100% rename from integration/src/routes/plugin/+layout.svelte rename to e2e/sveltekit/src/routes/plugin/+layout.svelte diff --git a/integration/src/routes/plugin/+layout.ts b/e2e/sveltekit/src/routes/plugin/+layout.ts similarity index 100% rename from integration/src/routes/plugin/+layout.ts rename to e2e/sveltekit/src/routes/plugin/+layout.ts diff --git a/integration/src/routes/plugin/fragment/update/+page.js b/e2e/sveltekit/src/routes/plugin/fragment/update/+page.js similarity index 100% rename from integration/src/routes/plugin/fragment/update/+page.js rename to e2e/sveltekit/src/routes/plugin/fragment/update/+page.js diff --git a/integration/src/routes/plugin/fragment/update/+page.svelte b/e2e/sveltekit/src/routes/plugin/fragment/update/+page.svelte similarity index 100% rename from integration/src/routes/plugin/fragment/update/+page.svelte rename to e2e/sveltekit/src/routes/plugin/fragment/update/+page.svelte diff --git a/integration/src/routes/plugin/fragment/update/spec.ts b/e2e/sveltekit/src/routes/plugin/fragment/update/spec.ts similarity index 100% rename from integration/src/routes/plugin/fragment/update/spec.ts rename to e2e/sveltekit/src/routes/plugin/fragment/update/spec.ts diff --git a/integration/src/routes/plugin/load/inlineAndGlobal/+page.js b/e2e/sveltekit/src/routes/plugin/load/inlineAndGlobal/+page.js similarity index 100% rename from integration/src/routes/plugin/load/inlineAndGlobal/+page.js rename to e2e/sveltekit/src/routes/plugin/load/inlineAndGlobal/+page.js diff --git a/integration/src/routes/plugin/load/inlineAndGlobal/+page.svelte b/e2e/sveltekit/src/routes/plugin/load/inlineAndGlobal/+page.svelte similarity index 100% rename from integration/src/routes/plugin/load/inlineAndGlobal/+page.svelte rename to e2e/sveltekit/src/routes/plugin/load/inlineAndGlobal/+page.svelte diff --git a/integration/src/routes/plugin/load/inlineAndGlobal/spec.ts b/e2e/sveltekit/src/routes/plugin/load/inlineAndGlobal/spec.ts similarity index 100% rename from integration/src/routes/plugin/load/inlineAndGlobal/spec.ts rename to e2e/sveltekit/src/routes/plugin/load/inlineAndGlobal/spec.ts diff --git a/integration/src/routes/plugin/load/list/+page.js b/e2e/sveltekit/src/routes/plugin/load/list/+page.js similarity index 100% rename from integration/src/routes/plugin/load/list/+page.js rename to e2e/sveltekit/src/routes/plugin/load/list/+page.js diff --git a/integration/src/routes/plugin/load/list/+page.svelte b/e2e/sveltekit/src/routes/plugin/load/list/+page.svelte similarity index 100% rename from integration/src/routes/plugin/load/list/+page.svelte rename to e2e/sveltekit/src/routes/plugin/load/list/+page.svelte diff --git a/integration/src/routes/plugin/load/list/spec.ts b/e2e/sveltekit/src/routes/plugin/load/list/spec.ts similarity index 100% rename from integration/src/routes/plugin/load/list/spec.ts rename to e2e/sveltekit/src/routes/plugin/load/list/spec.ts diff --git a/integration/src/routes/plugin/load/pageQuery-session/+page.gql b/e2e/sveltekit/src/routes/plugin/load/pageQuery-session/+page.gql similarity index 100% rename from integration/src/routes/plugin/load/pageQuery-session/+page.gql rename to e2e/sveltekit/src/routes/plugin/load/pageQuery-session/+page.gql diff --git a/integration/src/routes/plugin/load/pageQuery-session/+page.svelte b/e2e/sveltekit/src/routes/plugin/load/pageQuery-session/+page.svelte similarity index 100% rename from integration/src/routes/plugin/load/pageQuery-session/+page.svelte rename to e2e/sveltekit/src/routes/plugin/load/pageQuery-session/+page.svelte diff --git a/integration/src/routes/plugin/load/pageQuery-session/spec.ts b/e2e/sveltekit/src/routes/plugin/load/pageQuery-session/spec.ts similarity index 100% rename from integration/src/routes/plugin/load/pageQuery-session/spec.ts rename to e2e/sveltekit/src/routes/plugin/load/pageQuery-session/spec.ts diff --git a/integration/src/routes/plugin/load/pageQuery/+page.gql b/e2e/sveltekit/src/routes/plugin/load/pageQuery/+page.gql similarity index 100% rename from integration/src/routes/plugin/load/pageQuery/+page.gql rename to e2e/sveltekit/src/routes/plugin/load/pageQuery/+page.gql diff --git a/integration/src/routes/plugin/load/pageQuery/+page.svelte b/e2e/sveltekit/src/routes/plugin/load/pageQuery/+page.svelte similarity index 100% rename from integration/src/routes/plugin/load/pageQuery/+page.svelte rename to e2e/sveltekit/src/routes/plugin/load/pageQuery/+page.svelte diff --git a/integration/src/routes/plugin/load/pageQuery/spec.ts b/e2e/sveltekit/src/routes/plugin/load/pageQuery/spec.ts similarity index 100% rename from integration/src/routes/plugin/load/pageQuery/spec.ts rename to e2e/sveltekit/src/routes/plugin/load/pageQuery/spec.ts diff --git a/integration/src/routes/plugin/load/single/+page.js b/e2e/sveltekit/src/routes/plugin/load/single/+page.js similarity index 100% rename from integration/src/routes/plugin/load/single/+page.js rename to e2e/sveltekit/src/routes/plugin/load/single/+page.js diff --git a/integration/src/routes/plugin/load/single/+page.svelte b/e2e/sveltekit/src/routes/plugin/load/single/+page.svelte similarity index 100% rename from integration/src/routes/plugin/load/single/+page.svelte rename to e2e/sveltekit/src/routes/plugin/load/single/+page.svelte diff --git a/integration/src/routes/plugin/load/single/spec.ts b/e2e/sveltekit/src/routes/plugin/load/single/spec.ts similarity index 100% rename from integration/src/routes/plugin/load/single/spec.ts rename to e2e/sveltekit/src/routes/plugin/load/single/spec.ts diff --git a/integration/src/routes/plugin/query/afterLoad/+page.svelte b/e2e/sveltekit/src/routes/plugin/query/afterLoad/+page.svelte similarity index 100% rename from integration/src/routes/plugin/query/afterLoad/+page.svelte rename to e2e/sveltekit/src/routes/plugin/query/afterLoad/+page.svelte diff --git a/integration/src/routes/plugin/query/afterLoad/+page.ts b/e2e/sveltekit/src/routes/plugin/query/afterLoad/+page.ts similarity index 100% rename from integration/src/routes/plugin/query/afterLoad/+page.ts rename to e2e/sveltekit/src/routes/plugin/query/afterLoad/+page.ts diff --git a/integration/src/routes/plugin/query/afterLoad/spec.ts b/e2e/sveltekit/src/routes/plugin/query/afterLoad/spec.ts similarity index 100% rename from integration/src/routes/plugin/query/afterLoad/spec.ts rename to e2e/sveltekit/src/routes/plugin/query/afterLoad/spec.ts diff --git a/integration/src/routes/plugin/query/beforeLoad/+page.svelte b/e2e/sveltekit/src/routes/plugin/query/beforeLoad/+page.svelte similarity index 100% rename from integration/src/routes/plugin/query/beforeLoad/+page.svelte rename to e2e/sveltekit/src/routes/plugin/query/beforeLoad/+page.svelte diff --git a/integration/src/routes/plugin/query/beforeLoad/+page.ts b/e2e/sveltekit/src/routes/plugin/query/beforeLoad/+page.ts similarity index 100% rename from integration/src/routes/plugin/query/beforeLoad/+page.ts rename to e2e/sveltekit/src/routes/plugin/query/beforeLoad/+page.ts diff --git a/integration/src/routes/plugin/query/beforeLoad/spec.ts b/e2e/sveltekit/src/routes/plugin/query/beforeLoad/spec.ts similarity index 100% rename from integration/src/routes/plugin/query/beforeLoad/spec.ts rename to e2e/sveltekit/src/routes/plugin/query/beforeLoad/spec.ts diff --git a/integration/src/routes/plugin/query/component/+page.svelte b/e2e/sveltekit/src/routes/plugin/query/component/+page.svelte similarity index 100% rename from integration/src/routes/plugin/query/component/+page.svelte rename to e2e/sveltekit/src/routes/plugin/query/component/+page.svelte diff --git a/integration/src/routes/plugin/query/component/spec.ts b/e2e/sveltekit/src/routes/plugin/query/component/spec.ts similarity index 100% rename from integration/src/routes/plugin/query/component/spec.ts rename to e2e/sveltekit/src/routes/plugin/query/component/spec.ts diff --git a/integration/src/routes/plugin/query/layout/+layout.svelte b/e2e/sveltekit/src/routes/plugin/query/layout/+layout.svelte similarity index 100% rename from integration/src/routes/plugin/query/layout/+layout.svelte rename to e2e/sveltekit/src/routes/plugin/query/layout/+layout.svelte diff --git a/integration/src/routes/plugin/query/layout/+page.svelte b/e2e/sveltekit/src/routes/plugin/query/layout/+page.svelte similarity index 100% rename from integration/src/routes/plugin/query/layout/+page.svelte rename to e2e/sveltekit/src/routes/plugin/query/layout/+page.svelte diff --git a/integration/src/routes/plugin/query/layout/layout/spec.ts b/e2e/sveltekit/src/routes/plugin/query/layout/layout/spec.ts similarity index 100% rename from integration/src/routes/plugin/query/layout/layout/spec.ts rename to e2e/sveltekit/src/routes/plugin/query/layout/layout/spec.ts diff --git a/integration/src/routes/plugin/query/multiple/+page.svelte b/e2e/sveltekit/src/routes/plugin/query/multiple/+page.svelte similarity index 100% rename from integration/src/routes/plugin/query/multiple/+page.svelte rename to e2e/sveltekit/src/routes/plugin/query/multiple/+page.svelte diff --git a/integration/src/routes/plugin/query/multiple/spec.ts b/e2e/sveltekit/src/routes/plugin/query/multiple/spec.ts similarity index 100% rename from integration/src/routes/plugin/query/multiple/spec.ts rename to e2e/sveltekit/src/routes/plugin/query/multiple/spec.ts diff --git a/integration/src/routes/plugin/query/onError/+page.svelte b/e2e/sveltekit/src/routes/plugin/query/onError/+page.svelte similarity index 100% rename from integration/src/routes/plugin/query/onError/+page.svelte rename to e2e/sveltekit/src/routes/plugin/query/onError/+page.svelte diff --git a/integration/src/routes/plugin/query/onError/+page.ts b/e2e/sveltekit/src/routes/plugin/query/onError/+page.ts similarity index 100% rename from integration/src/routes/plugin/query/onError/+page.ts rename to e2e/sveltekit/src/routes/plugin/query/onError/+page.ts diff --git a/integration/src/routes/plugin/query/onError/spec.ts b/e2e/sveltekit/src/routes/plugin/query/onError/spec.ts similarity index 100% rename from integration/src/routes/plugin/query/onError/spec.ts rename to e2e/sveltekit/src/routes/plugin/query/onError/spec.ts diff --git a/integration/src/routes/plugin/query/scalars/+page.svelte b/e2e/sveltekit/src/routes/plugin/query/scalars/+page.svelte similarity index 100% rename from integration/src/routes/plugin/query/scalars/+page.svelte rename to e2e/sveltekit/src/routes/plugin/query/scalars/+page.svelte diff --git a/integration/src/routes/plugin/query/scalars/spec.ts b/e2e/sveltekit/src/routes/plugin/query/scalars/spec.ts similarity index 100% rename from integration/src/routes/plugin/query/scalars/spec.ts rename to e2e/sveltekit/src/routes/plugin/query/scalars/spec.ts diff --git a/integration/src/routes/plugin/query/simple/+page.svelte b/e2e/sveltekit/src/routes/plugin/query/simple/+page.svelte similarity index 100% rename from integration/src/routes/plugin/query/simple/+page.svelte rename to e2e/sveltekit/src/routes/plugin/query/simple/+page.svelte diff --git a/integration/src/routes/plugin/query/simple/spec.ts b/e2e/sveltekit/src/routes/plugin/query/simple/spec.ts similarity index 100% rename from integration/src/routes/plugin/query/simple/spec.ts rename to e2e/sveltekit/src/routes/plugin/query/simple/spec.ts diff --git a/integration/src/routes/plugin/query/variable-[id]/+page.svelte b/e2e/sveltekit/src/routes/plugin/query/variable-[id]/+page.svelte similarity index 100% rename from integration/src/routes/plugin/query/variable-[id]/+page.svelte rename to e2e/sveltekit/src/routes/plugin/query/variable-[id]/+page.svelte diff --git a/integration/src/routes/plugin/query/variable-[id]/+page.ts b/e2e/sveltekit/src/routes/plugin/query/variable-[id]/+page.ts similarity index 100% rename from integration/src/routes/plugin/query/variable-[id]/+page.ts rename to e2e/sveltekit/src/routes/plugin/query/variable-[id]/+page.ts diff --git a/integration/src/routes/plugin/query/variable-[id]/spec.ts b/e2e/sveltekit/src/routes/plugin/query/variable-[id]/spec.ts similarity index 100% rename from integration/src/routes/plugin/query/variable-[id]/spec.ts rename to e2e/sveltekit/src/routes/plugin/query/variable-[id]/spec.ts diff --git a/integration/src/routes/plugin/query/variables-error/+page.js b/e2e/sveltekit/src/routes/plugin/query/variables-error/+page.js similarity index 100% rename from integration/src/routes/plugin/query/variables-error/+page.js rename to e2e/sveltekit/src/routes/plugin/query/variables-error/+page.js diff --git a/integration/src/routes/plugin/query/variables-error/+page.svelte b/e2e/sveltekit/src/routes/plugin/query/variables-error/+page.svelte similarity index 100% rename from integration/src/routes/plugin/query/variables-error/+page.svelte rename to e2e/sveltekit/src/routes/plugin/query/variables-error/+page.svelte diff --git a/integration/src/routes/plugin/query/variables-error/spec.ts b/e2e/sveltekit/src/routes/plugin/query/variables-error/spec.ts similarity index 100% rename from integration/src/routes/plugin/query/variables-error/spec.ts rename to e2e/sveltekit/src/routes/plugin/query/variables-error/spec.ts diff --git a/e2e/sveltekit/src/routes/query-param/+error.svelte b/e2e/sveltekit/src/routes/query-param/+error.svelte new file mode 100644 index 0000000000..a4c4765d86 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/+error.svelte @@ -0,0 +1,12 @@ + + + + +User Not found... diff --git a/e2e/sveltekit/src/routes/query-param/+page.server.ts b/e2e/sveltekit/src/routes/query-param/+page.server.ts new file mode 100644 index 0000000000..4227aeb337 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/+page.server.ts @@ -0,0 +1,10 @@ +import { redirect } from '@sveltejs/kit'; +import type { PageServerLoad } from './$types'; + +export const load: PageServerLoad = async (event) => { + if (event.url.pathname.endsWith('query-param')) { + // fallback to user 2... because why not? + throw redirect(307, event.url.pathname + '/user-2'); + } + return {}; +}; diff --git a/e2e/sveltekit/src/routes/query-param/Loading.svelte b/e2e/sveltekit/src/routes/query-param/Loading.svelte new file mode 100644 index 0000000000..acd2706598 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/Loading.svelte @@ -0,0 +1,32 @@ + + +One eternity later... + + diff --git a/e2e/sveltekit/src/routes/query-param/UserName.svelte b/e2e/sveltekit/src/routes/query-param/UserName.svelte new file mode 100644 index 0000000000..c88a6429cf --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/UserName.svelte @@ -0,0 +1,25 @@ + + +{#if $data} + {$data.name} +{:else} + +{/if} diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.gql b/e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.gql new file mode 100644 index 0000000000..0fe20746c5 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.gql @@ -0,0 +1,6 @@ +query Layout_User($userId: ID!) { + user(id: $userId, snapshot: "Page_User", delay: 750) { + id + ...UserName + } +} diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.svelte b/e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.svelte new file mode 100644 index 0000000000..8555377fd3 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.svelte @@ -0,0 +1,59 @@ + + +user-1 +user-2 +user-3 + +

Page:

+ + + + diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.ts b/e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.ts new file mode 100644 index 0000000000..595ff0aa5a --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/+layout.ts @@ -0,0 +1,5 @@ +import type { Layout_UserVariables as variables } from './$houdini'; + +export const Layout_UserVariables: variables = ({ params }) => { + return { userId: params.userId }; +}; diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/+page.server.ts b/e2e/sveltekit/src/routes/query-param/user-[userId]/+page.server.ts new file mode 100644 index 0000000000..061b3269e6 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/+page.server.ts @@ -0,0 +1,11 @@ +import { redirect } from '@sveltejs/kit'; +import type { PageServerLoad } from './$types'; + +export const load: PageServerLoad = async (event) => { + if (event.url.pathname.endsWith('birth') || event.url.pathname.endsWith('friend')) { + return {}; + } + + // fallback to a default TAB if not set + throw redirect(307, event.url.pathname + '/birth'); +}; diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.gql b/e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.gql new file mode 100644 index 0000000000..64df9e38d2 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.gql @@ -0,0 +1,6 @@ +query Page_User_Birth($userId: ID!) { + user(id: $userId, snapshot: "Page_User", delay: 1000) { + id + birthDate + } +} diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.svelte b/e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.svelte new file mode 100644 index 0000000000..509edd10e6 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.svelte @@ -0,0 +1,31 @@ + + +

Tab: Birth

+ +{#if $Page_User_Birth.data?.user?.birthDate !== undefined} + {$Page_User_Birth.data?.user.birthDate?.toISOString().split('T')[0]} +{:else} + +{/if} + + +{#if $Page_User_Birth.isFetching} +
+
+
+
+ {console.log('isFetching in the console... when everything is cached, it should not be logged!')} +{/if} diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.ts b/e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.ts new file mode 100644 index 0000000000..717420c765 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/birth/+page.ts @@ -0,0 +1,6 @@ +import type { Page_User_BirthVariables as variables } from './$houdini'; + +// should be gone with https://github.com/HoudiniGraphql/houdini/issues/372 +export const Page_User_BirthVariables: variables = ({ params }) => { + return { userId: params.userId }; +}; diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.gql b/e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.gql new file mode 100644 index 0000000000..8956a9826b --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.gql @@ -0,0 +1,12 @@ +query Page_User_Firends($userId: ID!, $size: Int) { + user(id: $userId, snapshot: "Page_User", delay: 1200) { + id + friendsConnection(first: $size) { + edges { + node { + id + } + } + } + } +} diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.svelte b/e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.svelte new file mode 100644 index 0000000000..29acbf6ec5 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.svelte @@ -0,0 +1,16 @@ + + +

Tab: Number of Fiends

+ +{#if $Page_User_Firends.data?.user?.friendsConnection.edges} + {$Page_User_Firends.data?.user.friendsConnection.edges.length} +{:else} + +{/if} diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.ts b/e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.ts new file mode 100644 index 0000000000..87b54196db --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/friends/+page.ts @@ -0,0 +1,12 @@ +import type { Page_User_FirendsVariables as Variables } from './$houdini'; + +// should be gone with https://github.com/HoudiniGraphql/houdini/issues/372 +export const Page_User_FirendsVariables: Variables = ({ params, url }) => { + // 1 we know that Page_User can take a "size" and it's an Int + // 2 check if size is in searchParams + // 3 cast string to... primitives, or marchal (or the other one, I never know! the type... not the serialized one) + const rawSize = url.searchParams.get('size'); + const size: number | undefined = rawSize ? parseInt(rawSize, 10) : undefined; + + return { userId: params.userId, size }; +}; diff --git a/e2e/sveltekit/src/routes/query-param/user-[userId]/spec.ts b/e2e/sveltekit/src/routes/query-param/user-[userId]/spec.ts new file mode 100644 index 0000000000..b6d46c1e04 --- /dev/null +++ b/e2e/sveltekit/src/routes/query-param/user-[userId]/spec.ts @@ -0,0 +1,20 @@ +import { expect, test } from '@playwright/test'; +import { routes } from '../../../lib/utils/routes.js'; +import { expectToBe, expect_n_gql, goto, navSelector } from '../../../lib/utils/testsHelper.js'; + +test.describe('+Layout.gql', () => { + test('No GraphQL request & response happen (SSR)', async ({ page }) => { + await goto(page, routes.Query_param); + await expectToBe(page, 'Page: Samuel Jackson', 'h3'); + }); + + test('From HOME, navigate to page (only 1 graphql queries should happen, not more!)', async ({ + page + }) => { + await goto(page, routes.Home); + + const listStr = await expect_n_gql(page, navSelector(routes.Query_param), 1); + const expected = [`{"data":{"user":{"id":"Page_User:2","name":"Samuel Jackson"}}}`]; + expect(listStr).toStrictEqual(expected); + }); +}); diff --git a/integration/src/routes/spec.ts b/e2e/sveltekit/src/routes/spec.ts similarity index 100% rename from integration/src/routes/spec.ts rename to e2e/sveltekit/src/routes/spec.ts diff --git a/integration/src/routes/stores/endpoint-query/+page.server.ts b/e2e/sveltekit/src/routes/stores/endpoint-query/+page.server.ts similarity index 100% rename from integration/src/routes/stores/endpoint-query/+page.server.ts rename to e2e/sveltekit/src/routes/stores/endpoint-query/+page.server.ts diff --git a/integration/src/routes/stores/endpoint-query/+page.svelte b/e2e/sveltekit/src/routes/stores/endpoint-query/+page.svelte similarity index 100% rename from integration/src/routes/stores/endpoint-query/+page.svelte rename to e2e/sveltekit/src/routes/stores/endpoint-query/+page.svelte diff --git a/integration/src/routes/stores/endpoint-query/spec.ts b/e2e/sveltekit/src/routes/stores/endpoint-query/spec.ts similarity index 100% rename from integration/src/routes/stores/endpoint-query/spec.ts rename to e2e/sveltekit/src/routes/stores/endpoint-query/spec.ts diff --git a/integration/src/routes/stores/fragment-null/+page.svelte b/e2e/sveltekit/src/routes/stores/fragment-null/+page.svelte similarity index 100% rename from integration/src/routes/stores/fragment-null/+page.svelte rename to e2e/sveltekit/src/routes/stores/fragment-null/+page.svelte diff --git a/integration/src/routes/stores/fragment-null/spec.ts b/e2e/sveltekit/src/routes/stores/fragment-null/spec.ts similarity index 100% rename from integration/src/routes/stores/fragment-null/spec.ts rename to e2e/sveltekit/src/routes/stores/fragment-null/spec.ts diff --git a/integration/src/routes/stores/metadata/+page.svelte b/e2e/sveltekit/src/routes/stores/metadata/+page.svelte similarity index 88% rename from integration/src/routes/stores/metadata/+page.svelte rename to e2e/sveltekit/src/routes/stores/metadata/+page.svelte index 5fd53c0554..c97e4f0a18 100644 --- a/integration/src/routes/stores/metadata/+page.svelte +++ b/e2e/sveltekit/src/routes/stores/metadata/+page.svelte @@ -14,6 +14,8 @@ ); } + // there's nothing passing the session there to this fetch so the result is undefined + $: browser && GQL_Session.fetch({ metadata: { logResult: true }, diff --git a/integration/src/routes/stores/metadata/spec.ts b/e2e/sveltekit/src/routes/stores/metadata/spec.ts similarity index 89% rename from integration/src/routes/stores/metadata/spec.ts rename to e2e/sveltekit/src/routes/stores/metadata/spec.ts index ceeb89a7bf..edffc86536 100644 --- a/integration/src/routes/stores/metadata/spec.ts +++ b/e2e/sveltekit/src/routes/stores/metadata/spec.ts @@ -3,7 +3,7 @@ import { routes } from '../../../lib/utils/routes.js'; import { expect_1_gql, goto_expect_n_gql } from '../../../lib/utils/testsHelper.js'; test.describe('Metadata Page', () => { - test('Mutation => Should display the raw result in the console as info', async ({ page }) => { + test('Mutation => Should pass metadata', async ({ page }) => { // Listen to the console let displayed = ''; page.on('console', (msg) => { diff --git a/integration/src/routes/stores/mutation-enums/+page.svelte b/e2e/sveltekit/src/routes/stores/mutation-enums/+page.svelte similarity index 100% rename from integration/src/routes/stores/mutation-enums/+page.svelte rename to e2e/sveltekit/src/routes/stores/mutation-enums/+page.svelte diff --git a/integration/src/routes/stores/mutation-enums/spec.ts b/e2e/sveltekit/src/routes/stores/mutation-enums/spec.ts similarity index 100% rename from integration/src/routes/stores/mutation-enums/spec.ts rename to e2e/sveltekit/src/routes/stores/mutation-enums/spec.ts diff --git a/integration/src/routes/stores/mutation-scalars/+page.svelte b/e2e/sveltekit/src/routes/stores/mutation-scalars/+page.svelte similarity index 100% rename from integration/src/routes/stores/mutation-scalars/+page.svelte rename to e2e/sveltekit/src/routes/stores/mutation-scalars/+page.svelte diff --git a/integration/src/routes/stores/mutation-scalars/spec.ts b/e2e/sveltekit/src/routes/stores/mutation-scalars/spec.ts similarity index 100% rename from integration/src/routes/stores/mutation-scalars/spec.ts rename to e2e/sveltekit/src/routes/stores/mutation-scalars/spec.ts diff --git a/integration/src/routes/stores/mutation-update/+page.svelte b/e2e/sveltekit/src/routes/stores/mutation-update/+page.svelte similarity index 94% rename from integration/src/routes/stores/mutation-update/+page.svelte rename to e2e/sveltekit/src/routes/stores/mutation-update/+page.svelte index d71a870f21..0fb53e1b9b 100644 --- a/integration/src/routes/stores/mutation-update/+page.svelte +++ b/e2e/sveltekit/src/routes/stores/mutation-update/+page.svelte @@ -1,5 +1,5 @@ diff --git a/e2e/sveltekit/src/routes/stores/ssr/+page.ts b/e2e/sveltekit/src/routes/stores/ssr/+page.ts new file mode 100644 index 0000000000..c79e562211 --- /dev/null +++ b/e2e/sveltekit/src/routes/stores/ssr/+page.ts @@ -0,0 +1,15 @@ +import { usersListStore, HelloStore } from '$houdini'; +import type { LoadEvent } from '@sveltejs/kit'; + +export async function load(event: LoadEvent) { + const usersList = new usersListStore(); + const Hello = new HelloStore(); + + await Promise.all([usersList.fetch({ event }), Hello.fetch({ event })]); + + return { + test: 'hello', + usersList, + Hello + }; +} diff --git a/integration/src/routes/stores/ssr/spec.ts b/e2e/sveltekit/src/routes/stores/ssr/spec.ts similarity index 100% rename from integration/src/routes/stores/ssr/spec.ts rename to e2e/sveltekit/src/routes/stores/ssr/spec.ts diff --git a/integration/src/routes/stores/subunsub-list/+page.svelte b/e2e/sveltekit/src/routes/stores/subunsub-list/+page.svelte similarity index 100% rename from integration/src/routes/stores/subunsub-list/+page.svelte rename to e2e/sveltekit/src/routes/stores/subunsub-list/+page.svelte diff --git a/integration/src/routes/stores/subunsub-list/spec.ts b/e2e/sveltekit/src/routes/stores/subunsub-list/spec.ts similarity index 100% rename from integration/src/routes/stores/subunsub-list/spec.ts rename to e2e/sveltekit/src/routes/stores/subunsub-list/spec.ts diff --git a/integration/src/routes/stores/subunsub-mutation/+page.svelte b/e2e/sveltekit/src/routes/stores/subunsub-mutation/+page.svelte similarity index 100% rename from integration/src/routes/stores/subunsub-mutation/+page.svelte rename to e2e/sveltekit/src/routes/stores/subunsub-mutation/+page.svelte diff --git a/integration/src/routes/stores/withComp/+page.svelte b/e2e/sveltekit/src/routes/stores/withComp/+page.svelte similarity index 100% rename from integration/src/routes/stores/withComp/+page.svelte rename to e2e/sveltekit/src/routes/stores/withComp/+page.svelte diff --git a/integration/static/favicon.png b/e2e/sveltekit/static/favicon.png similarity index 100% rename from integration/static/favicon.png rename to e2e/sveltekit/static/favicon.png diff --git a/integration/svelte.config.js b/e2e/sveltekit/svelte.config.js similarity index 100% rename from integration/svelte.config.js rename to e2e/sveltekit/svelte.config.js diff --git a/integration/tsconfig.json b/e2e/sveltekit/tsconfig.json similarity index 100% rename from integration/tsconfig.json rename to e2e/sveltekit/tsconfig.json diff --git a/integration/vite.config.js b/e2e/sveltekit/vite.config.js similarity index 100% rename from integration/vite.config.js rename to e2e/sveltekit/vite.config.js diff --git a/example/houdini.config.js b/example/houdini.config.js index 8e78877195..44663169e2 100644 --- a/example/houdini.config.js +++ b/example/houdini.config.js @@ -1,6 +1,5 @@ /** @type {import('houdini').ConfigFile} */ const config = { - client: './src/client.ts', apiUrl: 'http://localhost:4000/graphql', scalars: { DateTime: { @@ -13,6 +12,11 @@ const config = { }, }, }, + plugins: { + 'houdini-svelte': { + client: './src/client.ts', + }, + }, } export default config diff --git a/example/package.json b/example/package.json index 118e82d15e..acfa80ce36 100644 --- a/example/package.json +++ b/example/package.json @@ -11,23 +11,24 @@ "start": "vite preview" }, "devDependencies": { - "@graphql-yoga/node": "2.8.0", + "@graphql-yoga/node": "^2.8.0", "@kitql/vite-plugin-watch-and-run": "^0.4.0", - "@sveltejs/kit": "1.0.0-next.445", + "@sveltejs/kit": "1.0.0-next.510", "concurrently": "^6.2.1", "graphql": "15.5.0", "houdini": "workspace:^", - "svelte": "^3.38.2", - "svelte-preprocess": "^4.0.0", - "tslib": "^2.2.0", - "typescript": "^4.0.0", - "vite": "^3.0.0", + "houdini-svelte": "workspace:^", + "svelte": "^3.50.0", + "svelte-preprocess": "^4.10.1", + "tslib": "^2.3.1", + "typescript": "^4.8.4", + "vite": "^3.1.0", "ws": "^8.8.1" }, "dependencies": { - "graphql-relay": "0.8.0", + "graphql-relay": "0.10.0", "graphql-tag": "2.12.6", - "graphql-ws": "5.8.2" + "graphql-ws": "^5.11.2" }, "type": "module" } diff --git a/example/src/lib/ItemEntry.svelte b/example/src/lib/ItemEntry.svelte index 50ef3f3d2d..1eb93b7098 100755 --- a/example/src/lib/ItemEntry.svelte +++ b/example/src/lib/ItemEntry.svelte @@ -6,6 +6,7 @@ // get the information we need about the item const data = fragment( + item, graphql` fragment ItemEntry_item on TodoItem { id @@ -13,8 +14,7 @@ completed createdAt } - `, - item + ` ) // create the functions we'll invoke to check, uncheck, and delete the item diff --git a/example/src/routes/+layout.js b/example/src/routes/+layout.js deleted file mode 100644 index 3644d5bcdb..0000000000 --- a/example/src/routes/+layout.js +++ /dev/null @@ -1,5 +0,0 @@ -import { browser } from '$app/environment' - -import houdiniClient from '../client' - -houdiniClient.init() diff --git a/example/src/routes/[filter]/+page.svelte b/example/src/routes/[filter]/+page.svelte index b122894720..600eaa9b22 100644 --- a/example/src/routes/[filter]/+page.svelte +++ b/example/src/routes/[filter]/+page.svelte @@ -1,32 +1,15 @@ -s

todos

- {#if $pageInfo.hasNextPage} + {#if $AllItems.pageInfo.hasNextPage} {/if}
    - {#each $data?.filteredItems.edges ?? [] as edge (edge.node?.id)} + {#each $AllItems.data?.filteredItems.edges ?? [] as edge (edge.node?.id)} {/each}
diff --git a/example/src/routes/[filter]/+page.ts b/example/src/routes/[filter]/+page.ts index 3810699b77..5e058df737 100644 --- a/example/src/routes/[filter]/+page.ts +++ b/example/src/routes/[filter]/+page.ts @@ -1,3 +1,27 @@ +import { graphql } from '$houdini' + +export const houdini_load = graphql` + query AllItems($completed: Boolean) @cache(policy: CacheOrNetwork) { + filteredItems: items(completed: $completed, first: 2) @paginate(name: "Filtered_Items") { + edges { + node { + id + completed + ...ItemEntry_item + } + } + } + allItems: items @list(name: "All_Items") { + edges { + node { + id + completed + } + } + } + } +` + export function AllItemsVariables({ params }) { // if there is no filter assigned, dont enforce one in the query if (!params.filter || params.filter === 'all') { diff --git a/example/src/routes/addItem/+page.svelte b/example/src/routes/addItem/+page.svelte deleted file mode 100644 index 1f49e03488..0000000000 --- a/example/src/routes/addItem/+page.svelte +++ /dev/null @@ -1,9 +0,0 @@ - - -