Skip to content

app dir next.config.js option crossOrigin: 'anonymous' not working #53190

Closed
@limi58

Description

@limi58

Verify canary release

  • I verified that the issue exists in the latest Next.js canary release

Provide environment information

Operating System:
      Platform: linux
      Arch: x64
      Version: #1 SMP Fri Jan 27 02:56:13 UTC 2023
    Binaries:
      Node: 18.16.0
      npm: 9.5.1
      Yarn: N/A
      pnpm: 8.6.2
    Relevant Packages:
      next: 13.4.12
      eslint-config-next: 13.4.12
      react: 18.2.0
      react-dom: 18.2.0
      typescript: 5.1.3
    Next.js Config:
      output: standalone

Which area(s) of Next.js are affected? (leave empty if unsure)

App Router

Link to the code that reproduces this issue or a replay of the bug

https://codesandbox.io/p/sandbox/boring-dust-mjv4ps

To Reproduce

  1. open above codesandbox link
  2. see next.config.js exises crossOrigin: 'anonymous' option
  3. open browser console, see script is not exises crossOrigin: 'anonymous'

Describe the Bug

nextjs v13, app dir, next.config.js exises crossOrigin: 'anonymous' option but not working

Expected Behavior

how to add crossOrigin='anonymous' to script ?

Which browser are you using? (if relevant)

Chrome 114.0.0.0

How are you deploying your application? (if relevant)

next start

NEXT-1475

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugIssue was opened via the bug report template.linear: nextConfirmed issue that is tracked by the Next.js team.locked

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions