Set `transform` to literal mode
Changes
- Updates
transformto use the "literal" mode that already powers theASTandTSXoutputs. - Turns out our parser could handle this use case, we just didn't flip the flag to make it do so.
- Found a few other issues while fixing this, including tests that had encoded the incorrect behavior.
- Closes #935. Closes PLT-1381.
Testing
Added new test for: Printer (JS), Printer (AST), Transform, Wasm output. Existing tests should pass. Updated old tests that relied on the previous behavior.
Docs
This is a bug fix
🦋 Changeset detected
Latest commit: 2974e55b20f85558728f5f0198479d076ebd1fcc
The changes in this PR will be included in the next version bump.
This PR includes changesets to release 1 package
| Name | Type |
|---|---|
| @astrojs/compiler | Minor |
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
!preview literal
> [email protected] release /home/runner/work/compiler/compiler > changeset publish "--tag" "next--literal" 🦋 warn ===============================IMPORTANT!=============================== 🦋 warn Packages will be released under the next--literal tag 🦋 warn ---------------------------------------------------------------------- 🦋 info npm info @astrojs/compiler 🦋 info @astrojs/compiler is being published because our local version (0.0.0-literal-20240111184948) has not been published on npm 🦋 info Publishing "@astrojs/compiler" at "0.0.0-literal-20240111184948" 🦋 success packages published successfully: 🦋 @astrojs/[email protected] 🦋 Creating git tag... 🦋 New tag: @astrojs/[email protected]
!preview literal
> [email protected] release /home/runner/work/compiler/compiler > changeset publish "--tag" "next--literal" 🦋 warn ===============================IMPORTANT!=============================== 🦋 warn Packages will be released under the next--literal tag 🦋 warn ---------------------------------------------------------------------- 🦋 info npm info @astrojs/compiler 🦋 info @astrojs/compiler is being published because our local version (0.0.0-literal-20240329135330) has not been published on npm 🦋 info Publishing "@astrojs/compiler" at "0.0.0-literal-20240329135330" 🦋 success packages published successfully: 🦋 @astrojs/[email protected] 🦋 Creating git tag... 🦋 New tag: @astrojs/[email protected]
Tested against core and this is breaking a bunch of tests there: https://github.com/withastro/astro/pull/10606
Yeah I believe it was because of the snapshot release having issues previously (which you pushed a fix for), tests passed locally for me IIRC, not sure though, been a little while 😀