diff --git a/.gitignore b/.gitignore index d97416cb..6003a002 100644 --- a/.gitignore +++ b/.gitignore @@ -10,4 +10,3 @@ package-lock.json .DS_Store /tsconfig.vitest-temp.json -/lsp diff --git a/package.json b/package.json index 2b8b4c6e..f7545106 100644 --- a/package.json +++ b/package.json @@ -11,8 +11,7 @@ "files": [ "LICENSE.md", "README.md", - "dist/", - "lsp/" + "dist/" ], "exports": { ".": { @@ -21,12 +20,6 @@ "require": "./dist/gql-tada.js", "source": "./src/index.ts" }, - "./lsp": { - "types": "./dist/graphqlsp.d.ts", - "import": "./dist/graphqlsp.module.js", - "require": "./dist/graphqlsp.js", - "source": "./src/lsp/index.ts" - }, "./package.json": "./package.json" }, "dependencies": { diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index b5b6f137..360e77f9 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -112,8 +112,8 @@ importers: specifier: ^4.2.2 version: 4.2.2(graphql@16.8.1) gql.tada: - specifier: workspace:* - version: link:../.. + specifier: file:../../gql.tada-1.0.0-beta.1.tgz + version: file:gql.tada-1.0.0-beta.1.tgz(graphql@16.8.1) react: specifier: ^18.2.0 version: 18.2.0 @@ -5548,3 +5548,17 @@ packages: resolution: {integrity: sha512-9bnSc/HEW2uRy67wc+T8UwauLuPJVn28jb+GtJY16iiKWyvmYJRXVT4UamsAEGQfPohgr2q4Tq0sQbQlxTfi1g==} engines: {node: '>=12.20'} dev: true + + file:gql.tada-1.0.0-beta.1.tgz(graphql@16.8.1): + resolution: {integrity: sha512-Vin00NTQUXWxnj5r/3yLE8DxzYdJgcihr6lqRlCtzY1QMzICRsu2zlBEoAqzUWtDIX9ZkuUSLamtWgsbqatzQA==, tarball: file:gql.tada-1.0.0-beta.1.tgz} + id: file:gql.tada-1.0.0-beta.1.tgz + name: gql.tada + version: 1.0.0-beta.1 + dependencies: + '@0no-co/graphql.web': 1.0.4(graphql@16.8.1) + '@0no-co/graphqlsp': 0.15.0(graphql@16.8.1) + transitivePeerDependencies: + - encoding + - graphql + - supports-color + dev: false diff --git a/src/lsp/index.ts b/src/lsp/index.ts deleted file mode 100644 index effcb4f0..00000000 --- a/src/lsp/index.ts +++ /dev/null @@ -1,23 +0,0 @@ -import type ts from 'typescript/lib/tsserverlibrary'; -import initGraphQLSP from '@0no-co/graphqlsp'; - -const init: ts.server.PluginModuleFactory = (ts) => { - const { create } = initGraphQLSP(ts); - return { - create(info) { - return create({ - ...info, - config: { - ...info.config, - schema: info.config.schema, - disableTypegen: true, - shouldCheckForColocatedFragments: true, - templateIsCallExpression: true, - template: 'graphql', - }, - }); - }, - }; -}; - -export default init;