Code Monkey home page Code Monkey logo

qiufen-vscode-extension's Introduction

graphql-qiufen-pro

graphql-qiufen-pro-docs

Features

  • graphql doc
  • Gqls modification is supported synchronously
  • Support graphql schema diff
  • Support operations field selection
  • To be added...

qiufen.config.js

// eslint-disable-next-line  @typescript-eslint/no-require-imports
const Mock = require('mockjs')

const { Random } = Mock

module.exports = {
  port: 5632,
  // Local schema file path
  localSchemaFile: './src/graphql/generated/schema.graphql',
  // "remote" | "local". When the remote gateway  fails, you are advised to set it to "local" and specify the path of the local schema file.
  schemaPolicy: 'remote',
  endpoint: {
    url: 'http://demo-address/graphql',
  },
  requestHeaders: {
    /** token */
    authorization:
      '++mcE48DJOpTMK1/+',
  },
  openGrouped: true,
  mock: {
    /** Whether all operations are mocking --> default-value: true */
    openAllOperationsMocking: false,
    /** operation-based need mocking */
    operations: {
      query: [],
      mutation: [],
      subscription: [],
    },
    /** mocks */
    scalarMap: {
      Int: () => Random.integer(0, 100),
      String: () => Random.ctitle(2, 4),
      ID: () => Random.id(),
      Boolean: () => Random.boolean(),
      BigDecimal: () => Random.integer(0, 1000000),
      Float: () => Random.float(0, 100),
      Date: () => Random.date(),
      DateTime: () => Random.datetime(),
      Long: () => Random.integer(0, 10000),
      NumberOrBoolOrStringOrNull: () => null,
      NumberOrString: () => null,
      Object: () => ({}),
    },
    resolvers: {
      Query: {
        /* Custom field interface return */
        // ListTaskBoardName: () => {
        //   return [
        //     {
        //       commodityNa3me: "111111111",
        //       commoditySpec2OptionName: "争11232131231212果",
        //       commodityType4Name: "样情",
        //       completedQuan4tity: "府委产",
        //       create4By: "火传离那",
        //     },
        //   ]
        // },
      },
    },
  },
}

qiufen-vscode-extension's People

Contributors

never-w avatar

Watchers

Yang Jing avatar zhenkaiZhao avatar LING_ZI_QING avatar Yingtao Mo avatar

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.