Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upcoming Release Changes #2764

Merged
merged 1 commit into from
Nov 26, 2024
Merged

Upcoming Release Changes #2764

merged 1 commit into from
Nov 26, 2024

Conversation

github-actions[bot]
Copy link
Contributor

@github-actions github-actions bot commented Nov 26, 2024

fixes #2178

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to master, this PR will be updated.

Releases

@graphql-eslint/[email protected]

Major Changes

  • #2598
    e771499
    Thanks @bmulholland! - 1. graphql plugin can now we be specified
    as

    plugins: {
    -  '@graphql-eslint': {
    -    graphqlPlugin.rules
    -  }
    +  '@graphql-eslint': graphqlPlugin
    }
    1. Config rules should now be accessed through the rules property

        rules: {
      -   ...graphqlESLint.configs['flat/operations-recommended']
      +   ...graphqlESLint.configs['flat/operations-recommended'].rules
    2. processor can now be specified with accessing processor property

      - processor: graphql.processors.graphql
      + processor: graphqlPlugin.processor
    3. The plugin can now be imported using a default import

      - import * as graphql from '@graphql-eslint/eslint-plugin'
      + import graphqlPlugin from '@graphql-eslint/eslint-plugin'
  • #1813
    1c2d220
    Thanks @dimaMachina! - - bring back possible-type-extension
    rule to schema-recommended config

    • add unique-operation-name and unique-fragment-name rules to operations-recommended config

    The concept of sibling operations provided by graphql-config's documents fields is based on
    uniquely named operations and fragments, for omitting false-positive/negative cases when
    operations and fragments are located in separate files. For this reason, these rules must be
    included in the recommended config

    • rename relay config to schema-relay

    To avoid confusing when users extend this config for executable definitions (operations and
    fragments)

  • #1813
    1c2d220
    Thanks @dimaMachina! - - alphabetize rule changes

    • add definitions: true option for schema-all/operations-all configs

    • rename values: ['EnumTypeDefinition'] to values: true

    • rename variables: ['OperationDefinition'] to variables: true

    • add groups: ['id', '*', 'createdAt', 'updatedAt'] for schema-all/operations-all configs

    • require-id-when-available rule changes

      • rename rule to require-selections
    • update schema-all/operations-all configs

    • require-description rule changes

      • add rootField: true option for schema-recommended config
    • require eslint at least >=8.44.0 as peerDependency

    • naming-convention

      • add new options for schema-recommended config
      {
        'EnumTypeDefinition,EnumTypeExtension': {
          forbiddenPrefixes: ['Enum'],
          forbiddenSuffixes: ['Enum']
        },
        'InterfaceTypeDefinition,InterfaceTypeExtension': {
          forbiddenPrefixes: ['Interface'],
          forbiddenSuffixes: ['Interface']
        },
        'UnionTypeDefinition,UnionTypeExtension': {
          forbiddenPrefixes: ['Union'],
          forbiddenSuffixes: ['Union']
        },
        'ObjectTypeDefinition,ObjectTypeExtension': {
          forbiddenPrefixes: ['Type'],
          forbiddenSuffixes: ['Type']
        }
      }
    • remove graphql-js' unique-enum-value-names rule

    • rename no-case-insensitive-enum-values-duplicates to unique-enum-value-names

      Since this rule reports case-insensitive enum values duplicates too

    • require-nullable-result-in-root rule changes

      Do not check subscriptions

  • #1813
    1c2d220
    Thanks @dimaMachina! - - remove parserOptions.schema

    • remove parserOptions.documents
    • remove parserOptions.extensions
    • remove parserOptions.include
    • remove parserOptions.exclude
    • remove parserOptions.projects
    • remove parserOptions.schemaOptions
    • remove parserOptions.graphQLParserOptions
    • remove parserOptions.skipGraphQLConfig
    • remove parserOptions.operations
    • add parserOptions.graphQLConfig?: IGraphQLConfig for programmatic usage
  • #2281
    c53cb4e
    Thanks @maciesielka! - Add new config option
    ignoredFieldSelectors to no-unused-fields rule to ignore all the relay pagination fields for
    every connection exposed in schema for example

  • #1813
    1c2d220
    Thanks @dimaMachina! - drop support of Node.js 12/14/16, GraphQL
    14/15

  • #2418
    c2d5386
    Thanks @comatory! - exposing GraphQLESTreeNode type

  • #2768
    241936a
    Thanks @dimaMachina! - - rename requireSiblingsOperations to
    requireGraphQLOperations

    • rename requireGraphQLSchemaFromContext to requireGraphQLSchema
  • #1813
    1c2d220
    Thanks @dimaMachina! - Remove GraphQLRuleTester from bundle,
    to test your rules use regular RuleTester from eslint

    Note: with this change unnecessary dependency @babel/code-frame was removed too

    import { RuleTester } from 'eslint'
    
    const ruleTester = new RuleTester({
      parser: require.resolve('@graphql-eslint/eslint-plugin')
    })
  • #2319
    b3c73dc
    Thanks @maciesielka! - Enforce require-selections on
    FragmentSpreads within GraphQLUnionTypes

Minor Changes

  • #2385
    afa8b8a
    Thanks @deathemperor! - feat: add a new option { for
    alphabetize rule to sort fields selection set

  • #2293
    01f7087
    Thanks @yoavsion! - Support the fragment spread group when defining
    alphabetize rule's groups with new option ...

  • #2719
    57d6edf
    Thanks @dimaMachina! - check for deprecated arguments and object
    field nodes in graphql operations in no-deprecated rule

Patch Changes

@github-actions github-actions bot force-pushed the changeset-release/master branch 2 times, most recently from 089d360 to 622ccee Compare November 26, 2024 13:37
@github-actions github-actions bot changed the title Upcoming Release Changes (alpha) Upcoming Release Changes Nov 26, 2024
@github-actions github-actions bot force-pushed the changeset-release/master branch from 622ccee to bc8b79c Compare November 26, 2024 13:39
@dimaMachina dimaMachina merged commit 28e6853 into master Nov 26, 2024
@dimaMachina dimaMachina deleted the changeset-release/master branch November 26, 2024 13:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Support "Flat Config" (ESLint 9)
1 participant