dotnet / dotnet/docfx

[Bug] Legal comments is missing for files that are generated by esbuild splitting feature

Open
#9,059 0 comments 0 reactions 0 assignees View on GitHub
compliance
Dominant language
C#
Stars
4.4k
Forks
890
Avg merge
2h 11m
Merged PRs (30d)
10

Description

**Describe the bug**
By default. esbuild output `legal comments` at the end of minified file.
https://esbuild.github.io/api/#legal-comments

For normal scripts/css files. It works as expected.
https://github.com/dotnet/docfx/blob/gh-pages/public/docfx.min.js#L71-L100

But some files generated by [esbuild splitting feature](https://esbuild.github.io/api/#splitting)
don't contains `legal-comments`. and restored source code from `.map` file also don't contains these comments.
https://github.com/dotnet/docfx/blob/gh-pages/public/es-ADFHJCQH.min.js

**To Reproduce**
Check [docfx site](https://dotnet.github.io/docfx) with browser's developer tools

**Expected behavior**
It can confirm third-party code license from distributed file.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.