Skip to content
New issue

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

Maintain sourcemap file extensions #171

Merged

Conversation

tagCincy
Copy link
Contributor

The regular expression for generating digested paths in propshaft is updated to accommodate sourcemap files. This will ensure the digested sourcemaps end -sha.ext.map instead of ext-sha.map. Services like Datadog that allow sourcemap uploads look specifically for files ending with .js.map, so this change allows compatibility. A corresponding test has been added in asset_test.rb, verifying that sourcemap files are correctly digesting their paths.

The regular expression for generating digested paths in propshaft is updated to accommodate sourcemap files too.  This will ensure the digested sourcemaps end `-sha.ext.map` instead of `ext-sha.map`. Services like Datadog that allow sourcemap uploads look specifically for files ending with `.js.map`, so this change allows compatibility. A corresponding test has been added in asset_test.rb, verifying that sourcemap files are correctly digesting their paths.
@brenogazzola
Copy link
Collaborator

Looks good, can you resolve the conflicts Github is complaning so we can merge please?

@dhh dhh merged commit bb7c462 into rails:main May 15, 2024
4 checks passed
dhh added a commit that referenced this pull request May 15, 2024
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.

3 participants