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

AtUri parses unicode domains incorrectly #2966

Open
tom-sherman opened this issue Nov 8, 2024 · 0 comments
Open

AtUri parses unicode domains incorrectly #2966

tom-sherman opened this issue Nov 8, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@tom-sherman
Copy link

Describe the bug

To Reproduce

Steps to reproduce the behavior:

> deno repl
Deno 2.0.5
exit using ctrl+d, ctrl+c, or close()
> import { AtUri } from "npm:@atproto/syntax"
undefined
> new AtUri("at://mañana.com")
AtUri {
  hash: "",
  host: "at:",
  pathname: "//mañana.com",
}

Expected behavior

I'd like for this to be punycode encoded to match the behaviour of the whatwg URL API ie.

AtUri {
  hash: "",
  host: "xn--maana-pta.com",
  pathname: "",
}

Details

  • Operating system: macos
  • Node version: v20.12.1

Additional context

@tom-sherman tom-sherman added the bug Something isn't working label Nov 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant