|
| 1 | +# Apollo IntelliJ Plugin |
| 2 | + |
| 3 | +[](https://plugins.jetbrains.com/plugin/20645) |
| 4 | +[](https://plugins.jetbrains.com/plugin/20645) |
| 5 | + |
| 6 | +<!-- Plugin description --> |
| 7 | + |
| 8 | +This plugin for Android Studio and IntelliJ helps you work with the |
| 9 | +[Apollo Kotlin](https://github.com/apollographql/apollo-kotlin) GraphQL library. |
| 10 | + |
| 11 | +## Features |
| 12 | +- Automatic code generation: models are re-generated whenever GraphQL files change |
| 13 | +- Integration with the [GraphQL IntelliJ Plugin](https://plugins.jetbrains.com/plugin/8097-js-graphql): the structure of the Apollo project is automatically contributed, so there is no need to create a `graphql.config.yml` / `.graphqlconfig` file |
| 14 | +- Navigation Kotlin code ⇄ GraphQL definitions |
| 15 | +- Unused operations and fields highlighting |
| 16 | +- Normalized cache viewer |
| 17 | +- Migration helpers: |
| 18 | + - Apollo Android 2.x → Apollo Kotlin 3.x |
| 19 | + - Apollo Kotlin 3.x → Apollo Kotlin 4.x |
| 20 | + - `compat` codegen → `operationBased` codegen |
| 21 | +- Integration with [Rover](https://www.apollographql.com/docs/rover) for a rich schema editing experience |
| 22 | +- More to come! |
| 23 | + |
| 24 | +## Compatibility |
| 25 | + |
| 26 | +- Most features are intended to work with Apollo Kotlin 4.x |
| 27 | +- Automatic code generation works with Apollo Kotlin 3.x and above |
| 28 | + |
| 29 | +<!-- Plugin description end --> |
| 30 | + |
| 31 | +The plugin is supported on: |
| 32 | + |
| 33 | +- IntelliJ 2024.2.1 and above |
| 34 | +- Android Studio 2024.2.1 (Ladybug) and above |
| 35 | + |
| 36 | +## Installation instructions |
| 37 | + |
| 38 | +<kbd>Marketplace</kbd> > Search for "Apollo GraphQL" > <kbd>Install</kbd> |
| 39 | + |
| 40 | +<img src="assets/instructions-3-search-and-install.png" width="600" /> |
| 41 | + |
| 42 | +### Weekly snapshots |
| 43 | + |
| 44 | +The plugin is published every Sunday in a specific **snapshots** repository. To use it, the repository URL must be |
| 45 | +configured: |
| 46 | + |
| 47 | +<kbd>Settings</kbd> > <kbd>Plugins</kbd> > <kbd>⚙</kbd>️ > <kbd>Manage Plugin |
| 48 | +Repositories</kbd> > <kbd>+</kbd> > <kbd>https://go.apollo.dev/ij-plugin-snapshots</kbd> |
| 49 | + |
| 50 | +<img src="assets/instructions-1-manage-repositories.png" width="600" /> |
| 51 | + |
| 52 | +<img src="assets/instructions-2-add-repository.png" width="600" /> |
| 53 | + |
| 54 | +Then search for "Apollo GraphQL" and install the plugin as usual. |
0 commit comments