Uncaught ReferenceError: gql is not defined


#1

Here is my code in client/startup.js:

import { registerGqlTag } from 'apollo-client/gql';

Meteor.startup(() => {
  registerGqlTag();
});

-- imports/app.js
const AppWithData = connect({
  mapQueriesToProps() {
    return {
      postsData: {
        query: gql`
            {
              posts{
                title
                content
              }
            }
          `
      }
    };
  }
})(App);

apollo-client v3.8.6


#2

That’s not a version that exists - can you check again? https://www.npmjs.com/package/apollo-client

BTW, the GitHub issues are probably a better place to post bugs!