Transformers completely ruin compilation #10027
Unanswered
chky-nmnsoftware
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I created the following
.parcelrcfile:{ "extends": "@parcel/config-default", "transformers": { "*.ts": ["./parcel-transformer.mjs", "..."] } }Additionally, I have the following
parcel-transformer.mjsfile:Now, I should expect that the project bundles as normal, however, when I run
parcel serve, I keep getting a "Failed to resolve 'hash' from 'script'" error. Additionally, my dist folder looks empty. If I were to use"*.ts": ["..."], it compiles correctly. Does anyone know why this is happening? I want to build a custom transformer that removes all lines of code that have a//removeCodecomment on top of them, however, if custom transformers don't work, then I can't even begin to test it.Beta Was this translation helpful? Give feedback.
All reactions