Skip to content

Feature: support href attribute in <image /> in collecting dependencies in HTMLTransformer#7482

Merged
devongovett merged 2 commits into
parcel-bundler:v2from
Shinyaigeek:feature/collect-href-as-deps-in-image-in-html
Dec 25, 2021
Merged

Feature: support href attribute in <image /> in collecting dependencies in HTMLTransformer#7482
devongovett merged 2 commits into
parcel-bundler:v2from
Shinyaigeek:feature/collect-href-as-deps-in-image-in-html

Conversation

@Shinyaigeek

@Shinyaigeek Shinyaigeek commented Dec 25, 2021

Copy link
Copy Markdown
Contributor

↪️ Pull Request

Rel: #7479 (fix?)

Hi team 👋

Currently, HTMLTransformer's collectDependencies cannot detect the image in <image href="" />.
xlink:href attribute in <image /> is supported by HTMLTransformer's collectDependencies, so I think it is reasonable to support also href attribute in <image />.

💻 Examples

<!doctype html>
<html>

<head>
</head>

<body>
  <svg>
    <image href="./100x100.png" />
  </svg>
</body>

</html>

🚨 Test instructions

I added an integration test to check whether or not parcel can detect an image in <Image href="" /> correctly.

✔️ PR Todo

  • Added/updated unit tests for this change
  • Filled out test instructions (In case there aren't any unit tests)
  • Included links to related issues/PRs

@height

height Bot commented Dec 25, 2021

Copy link
Copy Markdown

Link Height tasks by mentioning a task ID in the pull request title or commit messages, or description and comments with the keyword link (e.g. "Link T-123").

💡Tip: You can also use "Close T-X" to automatically close a task when the pull request is merged.

@devongovett devongovett merged commit af76afc into parcel-bundler:v2 Dec 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

@parcel/transformer-svg and @parcel/transformer-css clashing over CSS inline styles

3 participants