GithubHelp home page GithubHelp logo

Comments (6)

ngbinh avatar ngbinh commented on May 31, 2024 1

Thanks for the quick reply,

For Apollo style, the generated code contains import sangria.macros._. I don't think sangria has published artifact for scala.js. https://mvnrepository.com/artifact/org.sangria-graphql/sangria

For Sangria code gen style, I believe I had some trouble with scalar type when the generated code doesn't seem to include the type so it could not be compiled.

from sbt-graphql.

ngbinh avatar ngbinh commented on May 31, 2024 1

For Sangria code gen with scalar type, I will try to use ScalarAlias to see if it work and report back here.

from sbt-graphql.

muuki88 avatar muuki88 commented on May 31, 2024

Thanks for your feature request 🤗

What do you exactly mean? The generated sources should work for the JVM and scala.js. A shared project could contain all queries, which can be reused on both sides.

The Apollo style generation generates self contained query/mutation objects, so you don't have to worry about any "how to get the query from source" issues 😎

from sbt-graphql.

muuki88 avatar muuki88 commented on May 31, 2024

For Apollo style, the generated code contains import sangria.macros._. I don't think sangria has published artifact for scala.js

Ah, true. We only need that for the document parsing. If we can make this configurable to only use a string, the it would work.

Maybe we can tweak the Apollo style in this direction.

from sbt-graphql.

ngbinh avatar ngbinh commented on May 31, 2024

So 'ScalarAliasworks but notScalarType`.

from sbt-graphql.

jonas avatar jonas commented on May 31, 2024

Thanks for the clarification.
The recent #26 is about the missing support for ScalarType

from sbt-graphql.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.