aglinxinyuan opened a new issue, #4979:
URL: https://github.com/apache/texera/issues/4979
## Summary
`download.service.ts` carries a top-level `var contentDisposition =
require(\"content-disposition\")` that is never read or called anywhere in the
file or in the rest of `frontend/src`. The dependency itself is therefore dead
— it can be dropped along with its `@types/content-disposition` companion.
## Evidence
| | |
|---|---|
| `grep -rn 'contentDisposition' frontend/src` | 1 hit — the `require` line
itself; no read sites |
| `grep -rn 'content-disposition' frontend/src` | 1 hit — same line |
| Runtime use of \`contentDisposition\` | none |
| Compile use of \`@types/content-disposition\` | none (the require returns
\`any\` since it's CommonJS) |
## Before → After
\`\`\`
download.service.ts
┌──────────────────────────────────────────────────────────────────┐
│ ...imports... │
│ │
│ var contentDisposition = require(\"content-disposition\"); ← dead │
│ │
│ export const EXPORT_BASE_URL = ... │
└──────────────────────────────────────────────────────────────────┘
↓
┌──────────────────────────────────────────────────────────────────┐
│ ...imports... │
│ │
│ export const EXPORT_BASE_URL = ... │
└──────────────────────────────────────────────────────────────────┘
frontend/package.json
- dependencies.\"content-disposition\": \"0.5.4\"
- devDependencies.\"@types/content-disposition\": \"0\"
frontend/LICENSE-binary
- [email protected]
\`\`\`
## Verification plan
- [ ] \`yarn install\` succeeds and rewrites \`yarn.lock\` (transitive
entries for content-disposition fall away)
- [ ] \`yarn build\` exits 0
- [ ] \`yarn test\` keeps current parity (63 / 269)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]