Skip to content

Doesn't preserve // @license comments #560

Closed
@filipopo

Description

@filipopo

Terser preserves
/* @license magnet:?xt=urn:btih:0ef1b8170b3b615170ff270def6427c317705f85&dn=lgpl-3.0.txt LGPL-3.0 */
but not
// @license magnet:?xt=urn:btih:0ef1b8170b3b615170ff270def6427c317705f85&dn=lgpl-3.0.txt LGPL-3.0

e.g

npx terser msg.js --comments some

function sleep(ms){return new Promise(resolve=>setTimeout(resolve,ms))}
...

npx terser msg.js --comments all

// @license magnet:?xt=urn:btih:0ef1b8170b3b615170ff270def6427c317705f85&dn=lgpl-3.0.txt LGPL-3.0
function sleep(ms){return new Promise(resolve=>setTimeout(resolve,ms))}
...

Activity

fabiosantoscode

fabiosantoscode commented on Feb 3, 2020

@fabiosantoscode
Collaborator

Nice catch! These @xxx comments are mostly for jsdoc, but @license and others might not always be.

fabiosantoscode

fabiosantoscode commented on Feb 23, 2020

@fabiosantoscode
Collaborator

Fix will be released this week.

PS: Nobody's seeding that magnet link right now. I'll keep transmission on this week so if you seed it we can keep it alive :)

filipopo

filipopo commented on Feb 23, 2020

@filipopo
Author

Thanks for the patch.
I launched up my torrent client and got it, now I'm seeding but.. does anyone really need to download this? it's just an identifier for LibreJS, GNU's problem if it needs to download it too since it's their link.
I file bug reports to them tho

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @fabiosantoscode@filipopo

        Issue actions

          Doesn't preserve // @license comments · Issue #560 · terser/terser