https://github.com/remind101/autographcodegen
Swift GraphQL Code Generator
https://github.com/remind101/autographcodegen
Last synced: over 1 year ago
JSON representation
Swift GraphQL Code Generator
- Host: GitHub
- URL: https://github.com/remind101/autographcodegen
- Owner: remind101
- License: mit
- Created: 2023-07-03T01:54:53.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2024-10-10T18:43:55.000Z (almost 2 years ago)
- Last Synced: 2025-01-10T16:37:28.607Z (over 1 year ago)
- Language: Swift
- Size: 454 KB
- Stars: 1
- Watchers: 8
- Forks: 0
- Open Issues: 4
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# AutoGraphCodeGen
[](https://app.circleci.com/pipelines/github/remind101/AutoGraphCodeGen)
The Swiftest way to GraphQL Codegen
### Introspection
Usage: `./scripts/introspect-schema-json $SCHEMA_URL`.
See `./scripts/README.md` for more information.
### Testing
If you test from Xcode it will automatically code gen from the various test schemas in `./Tests/Resources`. Then simply rerun testing and it will attempt to compile the code gen'd code with the tests. If the code compiles on this second run, the "tests" have passed.
### Building
`swift build -c release --arch arm64 --arch x86_64` will build a release for supported architectures.
For more information see `https://www.smileykeith.com/2020/12/24/swiftpm-cross-compile/`.
The output binary will be located under `./.build/apple/Products/Release/AutoGraphCodeGen` if building from MacOS.
### Configuration
See example configuration in the Tests under file `test_autograph_codegen_config.json` and additionally look at `./Sources/libAutoGraphCodeGen/Configuration.swift` for configuration data structures and corresponding documentation.