Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

Recommended way of distributing SDK ?

Aperta
#554 0 commenti 9 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
20/100
Tipo di issue
Funzionalità
Chiarezza
Da chiarire
Stato di attività
Ferma
Stack tecnologico
graphql, typescript

Direzione di ricerca

Start with package.json and the graphclient build command, reproducing the reported failures with type: module, CommonJS output, and a separate consumer package. Trace the generated SDK's introspection and runtime dependency behavior; done would be a confirmed distribution approach or a clearly scoped implementation and documentation plan.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Hi,

I'm trying to build the generated SDK as a separate package (in the future also adding resolvers, etc).

What is the recommended way of building and distributing the generated SDK ?

I've tried a few things so far but I'm hitting a couple of roadblocks.

E.g. when having "type": "module" in my package.json file and running graphclient build I get introspection errors when generating the schema Failed to generate the schema Error: Failed to fetch introspection from xxxxx: TypeError [ERR_UNKNOWN_FILE_EXTENSION]: Unknown file extension ".ts"

If I remove "type": "module" I can build the graphclient and compile the typescript, but when I then try to use the package in a separete codebase I get Module not found: Can't resolve '@graphql-mesh/utils' at runtime.

If I build as CJS using graphclient build --fileType js and import that in my other repo, I also get Can't resolve '@graphql-mesh/utils'

Any advice is much appreciated !

Lingua principale
TypeScript
Stelle
186
Fork
49
Metriche di merge delle PR
Nessuna PR unita negli ultimi 30g

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di graphprotocol/graph-client

Tutte le issue di graphprotocol/graph-client

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.