withastro / astro

The web framework for content-driven websites. ⭐️ Star to support our work!
https://astro.build
Other
43.84k stars 2.28k forks source link

fix: check experimental flag when using the rewrite function #11349

Closed ematipico closed 2 days ago

ematipico commented 2 days ago

Changes

Closes https://github.com/withastro/docs/issues/8660

Testing

Manually tested

Docs

N/A

changeset-bot[bot] commented 2 days ago

🦋 Changeset detected

Latest commit: 9aa98d26b79d2b67c612203c3e41e4e0ce0a67ed

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

ematipico commented 2 days ago

Looks good but since it's duplicated, couldn't it be extracted to a shared function?

Definitely, but I'd prefer to do it in another to reduce the changes.