Skip to content

Commit

Permalink
fix: inverted
Browse files Browse the repository at this point in the history
  • Loading branch information
productdevbook committed Mar 1, 2024
1 parent 0cb27f0 commit a00bd82
Show file tree
Hide file tree
Showing 6 changed files with 1,538 additions and 1,151 deletions.
6 changes: 2 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ Simple relay cursor paging for graphql
pnpm add ts-relay-cursor-paging
```


## Demo

Open graphql playground in your browser port 4000/graphql
Expand Down Expand Up @@ -154,7 +153,7 @@ export const schema = createSchema({
libraries: async (_parent, _args, _context, _info) => {
const generator = datasLine()

async function resolveData({ offset, limit }: { offset: number; limit: number }) {
async function resolveData({ offset, limit }: { offset: number, limit: number }) {
const slicedData = generator.slice(offset, offset + limit)
return slicedData
}
Expand Down Expand Up @@ -206,7 +205,6 @@ Codes in this build are inspired by [pothos](https://github.com/hayes/pothos) an
</a>
</p>


## License

MIT License © 2022-PRESENT [productdevbook](https://github.com/productdevbook)
MIT License © 2022-PRESENT [productdevbook](https://github.com/productdevbook)
17 changes: 9 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -54,15 +54,16 @@
"graphql": "^16.8.0"
},
"devDependencies": {
"@antfu/eslint-config": "^1.1.0",
"@vitest/coverage-v8": "^0.34.6",
"bumpp": "^9.2.0",
"eslint": "^8.53.0",
"@antfu/eslint-config": "^2.6.4",
"@types/node": "^20.11.24",
"@vitest/coverage-v8": "^1.3.1",
"bumpp": "^9.3.0",
"eslint": "^8.57.0",
"graphql": "^16.8.1",
"tsup": "^7.2.0",
"typescript": "^5.2.2",
"vite": "^4.5.0",
"vitest": "^0.34.6"
"tsup": "^8.0.2",
"typescript": "^5.3.3",
"vite": "^5.1.4",
"vitest": "^1.3.1"
},
"publishConfig": {
"access": "public"
Expand Down
1 change: 1 addition & 0 deletions playground/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ export const schema = createSchema({
libraries: async (_parent, _args, _context, _info) => {
const generator = datasLine()

// eslint-disable-next-line style/member-delimiter-style
async function resolveData({ offset, limit }: { offset: number; limit: number }) {
const slicedData = generator.slice(offset, offset + limit)
return slicedData
Expand Down
Loading

0 comments on commit a00bd82

Please sign in to comment.