Javascript source code analysis ( specifically duplication checking )

后端 未结 3 374
眼角桃花
眼角桃花 2021-01-13 02:23

Partial duplicate of this

Notes: I already use JSLint extensively via a tool I wrote that scans in intervals my current project directory for recently updated/create

相关标签:
3条回答
  • 2021-01-13 02:53

    Our CloneDR is a tool for finding exact and near-miss cloned code blocks for a variety of languages. It will find duplicates in the same file or across literally thousands of files if you have them. You don't have to provide it with any guidance; it can find the cloned code by itself. And it won't be fooled by different indentation or line breaks, or even consistent renaming of identifiers

    It does support JavaScript, even if it isn't clear from the website.

    You can see sample clone reports for a variety of langauges at the website.

    0 讨论(0)
  • 2021-01-13 02:54

    You may want to have a look at jsinspect.

    jsinspect ./src
    

    It will print a list of code blocks that are either identical or structurally very similar.

    And there's also jscpd.

    0 讨论(0)
  • 2021-01-13 03:10

    May not be exactly what your after, but Google's Javascript optimizer is worth a look.

    0 讨论(0)
提交回复
热议问题