houfeng / gq-loader Goto Github PK
View Code? Open in Web Editor NEWThe best GraphQL Loader for Webpack
The best GraphQL Loader for Webpack
是否可以向.graphql文件添加多个查询
I used google translate, but I want to know if I can have 2 queries in one file.
Thanks!
query rateListQuery($RatePage: RatePage) {
rateList(item: $RatePage) {
docs {
...rateFields
goodsInfo {
name
}
}
total
page
limit
}
}
mutation rateUpDown($RateUpdate: RateUpdate) {
rateUpdate(item: $RateUpdate) {
_id
state
}
}
只能导出 rateListQuery,我看了源码,发现 就是这样,但是文档不是,我想用文档中那种,一个文件 能导出多个 方法。
请教是不是 我用的不对?
Node 10.5
query MyQuery($querys: RateQuery, $sort: Sort, $pagination: Pagination) {
rateList(querys: $querys, sort: $sort, pagination: $pagination) {
docs {
orderNumber
content
createdDate
created
nickName
timestamp
state
rate
imgs
_id
goodsInfo {
name
}
}
total
page
limit
}
}
input RateQuery {
state: String
startTime: String
endTime: String
}
input Sort {
key: String
order: String
}
input Pagination {
current: Int
pageSize: Int
}
RateQuery、Sort、Pagination 都报错 定义未执行:
调用处:
import getRate from './getRate.gql';
.......
const result = await getRate(params);
请问是什么原因呀?
Please translate the readme to english so every one could understand what this package does
windows下报错
ERROR Failed to compile with 1 errors 3:12:11 PM
This dependency was not found:
To install it, you can run: npm install --save E:wwwgq-loader
equest.jsesgq-loaderlib
ERROR CODE ERR_WEBPACK_MODULE_NOT_FOUND
DETAILS
1. 文件确实不存在
2. 大小写问题
如果 mac 下构建成功,而在 linux 下或云构建平台上构建失败,则基本可断定为大小写问题。
如果是大小写问题,请仔细检查 import 或 require 的文件和目标文件的大小写是否一致。
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.