Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/tituskirch/pageinfotype
A PageInfoType according to relay for apollo server.
https://github.com/tituskirch/pageinfotype
apolloserver graphql page-infotype relay
Last synced: 26 days ago
JSON representation
A PageInfoType according to relay for apollo server.
- Host: GitHub
- URL: https://github.com/tituskirch/pageinfotype
- Owner: TitusKirch
- License: mit
- Created: 2020-12-13T19:21:40.000Z (almost 4 years ago)
- Default Branch: main
- Last Pushed: 2023-01-16T14:05:10.000Z (almost 2 years ago)
- Last Synced: 2024-09-07T09:57:00.023Z (2 months ago)
- Topics: apolloserver, graphql, page-infotype, relay
- Language: JavaScript
- Homepage: https://github.com/tituskirch/pageinfotype#readme
- Size: 515 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Welcome to @tituskirch/pageinfotype 👋
> A PageInfoType according to relay for apollo server.
## Hot to use
First install the package```BASH
npm i @tituskirch/pageinfotype
```Then import the type definition.
```TS
import pageinfotype from '@tituskirch/pageinfotype'
```Now you can merge `pageinfotype.typeDef` with your other TypeDefs and pass it to the ApolloServer. In your TypeDefs you can now access the type `PageInfo` without any problems. Remember to write a resolver for PageInfo.
## TypeDef
```graphql
type PageInfo {
hasNextPage: Boolean
hasPreviousPage: Boolean
startCursor: String!
endCursor: String!
}
```## Commands
|Command|Aliases|Description|
|---|---|---|
|`npm run build:production`|`npm run build`| Builds the app with the production settings. |
|`npm run build:dev`|`npm run build:development`| Builds the app with the development settings. |
|`npm run start`| - | Starts the app with the `.env` file. |
|`npm run start:watch`| - | Starts the app with the `.env` file and nodemon. |
|`npm run eslint`| - | Run ESLint to check the code style. |## Author
👤 **Titus Kirch**
- Website: https://tkirch.dev
- Twitter: [@TitusKirch](https://twitter.com/TitusKirch)
- Github: [@TitusKirch](https://github.com/TitusKirch)
- LinkedIn: [@TitusKirch](https://linkedin.com/in/TitusKirch)## 🤝 Contributing
Contributions, issues and feature requests are welcome!
Feel free to check [issues page](https://github.com/tkirchDev/pageinfotype/issues). You can also take a look at the [contributing guide](https://github.com/tkirchDev/pageinfotype/blob/master/CONTRIBUTING.md).## Show your support
Give a ⭐️ if this project helped you!
## 📝 License
Copyright © 2020 [Titus Kirch](https://github.com/tkirchDev).
This project is [MIT](https://github.com/tkirchDev/pageinfotype/blob/master/LICENSE) licensed.---
_This README was generated with ❤️ by [readme-md-generator](https://github.com/kefranabg/readme-md-generator)_