Skip to content

馃拝 useNamingConvention does not ignore declare global namespaces聽#11566

Description

@Jugbot

Environment information

Details
CLI:
  Version:                      2.5.10
  Color support:                true

Platform:
  CPU Architecture:             aarch64
  OS:                           macos

Environment:
  BIOME_DISTRIBUTION:                unset
  BIOME_LOG_FILE:                    unset
  BIOME_LOG_PATH:                    unset
  BIOME_LOG_PREFIX_NAME:             unset
  BIOME_LOG_LEVEL:                   unset
  BIOME_LOG_KIND:                    unset
  BIOME_CONFIG_PATH:                 unset
  BIOME_THREADS:                     unset
  BIOME_WATCHER_KIND:                unset
  BIOME_WATCHER_POLLING_INTERVAL:    unset
  BIOME_BINARY:                      unset
  RUST_BACKTRACE:                    unset
  NO_COLOR:                     unset
  TERM:                         xterm-256color
  JS_RUNTIME_VERSION:           unset
  JS_RUNTIME_NAME:              unset
  NODE_PACKAGE_MANAGER:         unset

Biome Configuration:
  Status:                       Loaded successfully.
  Path:                         biome.json
  Formatter enabled:            true
  Linter enabled:               true
  Assist enabled:               true
  VCS enabled:                  true
  HTML full support enabled:    unset

Rule name

style/useNamingConvention

Playground link

https://biomejs.dev/playground/?lintRules=useNamingConvention&tab=analyzer-fixes&pane=Diagnostics#code=ZABlAGMAbABhAHIAZQAgAGcAbABvAGIAYQBsACAAewAKACAAIABuAGEAbQBlAHMAcABhAGMAZQAgAEoAUwBYACAAewAKACAAIAB9AAoAfQA%3D

Expected result

There should be no suggested fixes for namespaces within declare global blocks as described by the rule docs.
https://biomejs.dev/linter/rules/use-naming-convention/javascript/#ignored-declarations

declare global {
  // The casing of `JSX` should not be changed to `Jsx`
  namespace JSX {
  }
}

Code of Conduct

  • I agree to follow Biome's Code of Conduct

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-LinterArea: linterL-JavaScriptLanguage: JavaScript and super languagesS-Bug-confirmedStatus: report has been confirmed as a valid bug

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions