We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
See also a similar bug in TypeScript: microsoft/TypeScript#47219
esbuild rejects the following code:
import React from "react"; export function MyComponent() { return <svg : path />; }
$ npx esbuild hello.jsx --bundle --external:react ✘ [ERROR] Expected ">" but found ":" hello.jsx:3:14: 3 │ return <svg : path />; │ ^ ╵ > 1 error
According to the JSX specification, whitespace is allowed around the : token.
:
Babel, ESLint, and Flow interpret this code correctly, treating svg:path as the tag's name.
svg:path
esbuild does parse the following correctly (I think; I haven't fully tested):
import React from "react"; export function MyComponent() { return <svg:path />; }
$ npx esbuild hello.jsx --bundle --external:react [snip] // hello.jsx var import_react = __toESM(__require("react")); function MyComponent() { return /* @__PURE__ */ import_react.default.createElement("svg:path", null); } })();
The text was updated successfully, but these errors were encountered:
54f7c63
No branches or pull requests
See also a similar bug in TypeScript: microsoft/TypeScript#47219
esbuild rejects the following code:
According to the JSX specification, whitespace is allowed around the
:
token.Babel, ESLint, and Flow interpret this code correctly, treating
svg:path
as the tag's name.esbuild does parse the following correctly (I think; I haven't fully tested):
The text was updated successfully, but these errors were encountered: