[{"data":1,"prerenderedAt":621},["ShallowReactive",2],{"navigation_docs":3,"trending-repo-cs341-illinois\u002Fcoursebook":249,"page-views-\u002Ftrending\u002Fcs341-illinois\u002Fcoursebook":619},[4,29,104,124,194],{"title":5,"icon":6,"path":7,"stem":8,"children":9},"Start",false,"\u002Fstart","1.start",[10,14,19,24],{"title":11,"path":7,"stem":12,"icon":13},"What jscpd finds","1.start\u002Findex","i-lucide-house",{"title":15,"path":16,"stem":17,"icon":18},"Installation","\u002Fstart\u002Finstallation","1.start\u002F2.installation","i-lucide-download",{"title":20,"path":21,"stem":22,"icon":23},"Quickstart","\u002Fstart\u002Fquickstart","1.start\u002F3.quickstart","i-lucide-rocket",{"title":25,"path":26,"stem":27,"icon":28},"Configuration basics","\u002Fstart\u002Fconfiguration","1.start\u002F4.configuration","i-lucide-settings-2",{"title":30,"icon":6,"path":31,"stem":32,"children":33,"page":6},"Guides","\u002Fguides","2.guides",[34,39,44,49,54,59,64,69,74,79,84,89,94,99],{"title":35,"path":36,"stem":37,"icon":38},"Use jscpd in CI","\u002Fguides\u002Fci","2.guides\u002F01.ci","i-lucide-github",{"title":40,"path":41,"stem":42,"icon":43},"Pre-commit hooks","\u002Fguides\u002Fpre-commit","2.guides\u002F02.pre-commit","i-lucide-git-commit",{"title":45,"path":46,"stem":47,"icon":48},"Fail only on new duplication","\u002Fguides\u002Fbaseline","2.guides\u002F03.baseline","i-lucide-git-compare",{"title":50,"path":51,"stem":52,"icon":53},"Monorepos","\u002Fguides\u002Fmonorepos","2.guides\u002F04.monorepos","i-lucide-folder-tree",{"title":55,"path":56,"stem":57,"icon":58},"Cross-format detection","\u002Fguides\u002Fcross-format","2.guides\u002F05.cross-format","i-lucide-layers",{"title":60,"path":61,"stem":62,"icon":63},"Agents","\u002Fguides\u002Fagents","2.guides\u002F06.agents","i-lucide-cpu",{"title":65,"path":66,"stem":67,"icon":68},"Editors","\u002Fguides\u002Feditors","2.guides\u002F07.editors","i-lucide-code",{"title":70,"path":71,"stem":72,"icon":73},"Duplication over git history","\u002Fguides\u002Fhistory","2.guides\u002F08.history","i-lucide-chart-no-axes-combined",{"title":75,"path":76,"stem":77,"icon":78},"Dashboard and health score","\u002Fguides\u002Fdashboard","2.guides\u002F09.dashboard","i-lucide-layout-dashboard",{"title":80,"path":81,"stem":82,"icon":83},"Dead code","\u002Fguides\u002Fdead-code","2.guides\u002F10.dead-code","i-lucide-ghost",{"title":85,"path":86,"stem":87,"icon":88},"Comparing two codebases","\u002Fguides\u002Fcompare","2.guides\u002F11.compare","i-lucide-git-compare-arrows",{"title":90,"path":91,"stem":92,"icon":93},"Semantic clones","\u002Fguides\u002Fsemantic-clones","2.guides\u002F12.semantic-clones","i-lucide-brain-circuit",{"title":95,"path":96,"stem":97,"icon":98},"Similar functions","\u002Fguides\u002Fsimilarity","2.guides\u002F13.similarity","i-lucide-list-tree",{"title":100,"path":101,"stem":102,"icon":103},"Boundaries","\u002Fguides\u002Fboundaries","2.guides\u002F14.boundaries","i-lucide-fence",{"title":105,"icon":6,"path":106,"stem":107,"children":108,"page":6},"Concepts","\u002Fconcepts","3.concepts",[109,114,119],{"title":110,"path":111,"stem":112,"icon":113},"Types of code clones","\u002Fconcepts\u002Fclone-types","3.concepts\u002F1.clone-types","i-lucide-copy",{"title":115,"path":116,"stem":117,"icon":118},"How detection works","\u002Fconcepts\u002Fhow-detection-works","3.concepts\u002F2.how-detection-works","i-lucide-scan-search",{"title":120,"path":121,"stem":122,"icon":123},"The health score","\u002Fconcepts\u002Fhealth-score","3.concepts\u002F3.health-score","i-lucide-heart-pulse",{"title":125,"icon":6,"path":126,"stem":127,"children":128,"page":6},"Reference","\u002Freference","4.reference",[129,134,139,144,181,186,190],{"title":130,"path":131,"stem":132,"icon":133},"CLI options","\u002Freference\u002Fcli","4.reference\u002F1.cli","i-lucide-terminal",{"title":135,"path":136,"stem":137,"icon":138},"The config file","\u002Freference\u002Fconfig-file","4.reference\u002F2.config-file","i-lucide-settings",{"title":140,"path":141,"stem":142,"icon":143},"Exit codes","\u002Freference\u002Fexit-codes","4.reference\u002F3.exit-codes","i-lucide-log-out",{"title":145,"icon":6,"path":146,"stem":147,"children":148},"Reporters","\u002Freference\u002Freporters","4.reference\u002F4.reporters\u002Findex",[149,151,156,161,166,171,176],{"title":145,"path":146,"stem":147,"icon":150},"i-lucide-file-chart-column",{"title":152,"path":153,"stem":154,"icon":155},"HTML reporter","\u002Freference\u002Freporters\u002Fhtml","4.reference\u002F4.reporters\u002F2.html","i-lucide-file-code",{"title":157,"path":158,"stem":159,"icon":160},"JSON reporter","\u002Freference\u002Freporters\u002Fjson","4.reference\u002F4.reporters\u002F3.json","i-lucide-braces",{"title":162,"path":163,"stem":164,"icon":165},"Badge reporter","\u002Freference\u002Freporters\u002Fbadge","4.reference\u002F4.reporters\u002F4.badge","i-lucide-award",{"title":167,"path":168,"stem":169,"icon":170},"SARIF reporter","\u002Freference\u002Freporters\u002Fsarif","4.reference\u002F4.reporters\u002F5.sarif","i-lucide-shield-check",{"title":172,"path":173,"stem":174,"icon":175},"CodeClimate reporter","\u002Freference\u002Freporters\u002Fcodeclimate","4.reference\u002F4.reporters\u002F6.codeclimate","i-lucide-flag-triangle-right",{"title":177,"path":178,"stem":179,"icon":180},"OpenMetrics reporter","\u002Freference\u002Freporters\u002Fopenmetrics","4.reference\u002F4.reporters\u002F7.openmetrics","i-lucide-activity",{"title":182,"path":183,"stem":184,"icon":185},"Supported formats","\u002Freference\u002Fsupported-formats","4.reference\u002F5.supported-formats","i-lucide-languages",{"title":187,"path":188,"stem":189,"icon":38},"GitHub Action","\u002Freference\u002Fgithub-action","4.reference\u002F6.github-action",{"title":191,"path":192,"stem":193,"icon":68},"Rust crates","\u002Freference\u002Frust-crates","4.reference\u002F7.rust-crates",{"title":195,"icon":6,"path":196,"stem":197,"children":198,"page":6},"Project","\u002Fproject","5.project",[199,204,209,214,239,244],{"title":200,"path":201,"stem":202,"icon":203},"Changelog","\u002Fproject\u002Fchangelog","5.project\u002F1.changelog","i-lucide-scroll-text",{"title":205,"path":206,"stem":207,"icon":208},"Migrating from v4 to v5","\u002Fproject\u002Fmigration","5.project\u002F2.migration","i-lucide-arrow-right-left",{"title":210,"path":211,"stem":212,"icon":213},"jscpd v4 (TypeScript)","\u002Fproject\u002Fv4","5.project\u002F3.v4","i-simple-icons-typescript",{"title":215,"icon":6,"path":216,"stem":217,"children":218},"Benchmarks","\u002Fproject\u002Fbenchmarks","5.project\u002F4.benchmarks\u002Findex",[219,221,226,230,235],{"title":215,"path":216,"stem":217,"icon":220},"i-lucide-gauge",{"title":222,"path":223,"stem":224,"icon":225},"Detection Speed","\u002Fproject\u002Fbenchmarks\u002Fdetection-speed","5.project\u002F4.benchmarks\u002F2.detection-speed","i-lucide-zap",{"title":227,"path":228,"stem":229,"icon":58},"Multi-Format Detection","\u002Fproject\u002Fbenchmarks\u002Fcross-format","5.project\u002F4.benchmarks\u002F3.cross-format",{"title":231,"path":232,"stem":233,"icon":234},"AI Token Efficiency","\u002Fproject\u002Fbenchmarks\u002Fai-token-efficiency","5.project\u002F4.benchmarks\u002F4.ai-token-efficiency","i-lucide-sparkles",{"title":236,"path":237,"stem":238,"icon":93},"Embedding Models","\u002Fproject\u002Fbenchmarks\u002Fembedding-models","5.project\u002F4.benchmarks\u002F5.embedding-models",{"title":240,"path":241,"stem":242,"icon":243},"Research","\u002Fproject\u002Fresearch","5.project\u002F5.research","i-lucide-graduation-cap",{"title":245,"path":246,"stem":247,"icon":248},"Articles","\u002Fproject\u002Farticles","5.project\u002F6.articles","i-lucide-newspaper",{"name":250,"url":251,"appearances":252,"latest":273},"cs341-illinois\u002Fcoursebook","https:\u002F\u002Fgithub.com\u002Fcs341-illinois\u002Fcoursebook",[253,268],{"date":254,"rank":255,"stars":256,"starsToday":257,"headSha":258,"sources":259,"lines":260,"clones":261,"duplicatedLines":262,"percentage":263,"codePercentage":264,"codeSources":265,"healthScore":266,"healthGrade":267},"2026-09-29",4,2615,195,"61c706f1037dab30feac2e4bb852c01c9257af64",120,98419,564,57908,58.84,1.6,20,57.1,"C",{"date":269,"rank":270,"stars":271,"starsToday":272,"headSha":258,"sources":259,"lines":260,"clones":261,"duplicatedLines":262,"percentage":263,"codePercentage":264,"codeSources":265,"healthScore":266,"healthGrade":267},"2026-09-30",8,3187,572,{"date":269,"generatedAt":274,"name":250,"url":251,"description":275,"language":276,"stars":271,"starsToday":272,"defaultBranch":277,"headSha":258,"durationMs":278,"total":279,"formats":283,"topClones":325,"health":455,"complexity":483,"deadCode":536,"code":565,"measuredAt":617,"jscpdVersion":618},"2026-09-30T05:32:45.199Z","Open Source Introductory Systems Programming Textbook for the University of Illinois","TeX","master",155,{"sources":259,"lines":260,"tokens":280,"clones":261,"duplicatedLines":262,"duplicatedTokens":281,"percentage":263,"percentageTokens":282},486800,216904,44.56,[284,291,297,304,311,316,320,322],{"format":285,"sources":286,"lines":287,"clones":288,"duplicatedLines":289,"percentage":290},"markup",52,79082,553,57782,73.07,{"format":292,"sources":293,"lines":294,"clones":270,"duplicatedLines":295,"percentage":296},"latex",34,16818,73,0.43,{"format":298,"sources":299,"lines":300,"clones":301,"duplicatedLines":302,"percentage":303},"python",5,593,2,26,4.38,{"format":305,"sources":306,"lines":307,"clones":308,"duplicatedLines":309,"percentage":310},"yaml",3,174,1,27,15.52,{"format":312,"sources":313,"lines":314,"clones":315,"duplicatedLines":315,"percentage":315},"bash",14,863,0,{"format":317,"sources":318,"lines":319,"clones":315,"duplicatedLines":315,"percentage":315},"markdown",10,698,{"format":321,"sources":308,"lines":307,"clones":315,"duplicatedLines":315,"percentage":315},"perl",{"format":323,"sources":308,"lines":324,"clones":315,"duplicatedLines":315,"percentage":315},"text",17,[326,350,372,390,398,409,420,429,438,447],{"format":285,"lines":327,"tokens":328,"first":329,"others":333,"copies":306,"excerpt":338,"kind":285},2344,8225,{"name":330,"start":331,"end":332},"deadlock\u002Fdrawings\u002Fdining_arbitrator.svg",38,2381,[334,336],{"name":335,"start":331,"end":332},"deadlock\u002Fdrawings\u002Fdining_livelock.svg",{"name":337,"start":331,"end":332},"deadlock\u002Fdrawings\u002Fdining_partial.svg",{"lines":339,"total":327},[340,341,342,343,344,345,346,347,348,349],"   inkscape:current-layer=\"svg8\"","   fit-margin-top=\"0\"","   fit-margin-left=\"0\"","   fit-margin-right=\"0\"","   fit-margin-bottom=\"0\" \u002F>","\u003Cdefs","   id=\"defs2\">","  \u003Cinkscape:path-effect","     effect=\"bspline\"","     id=\"path-effect3001\"",{"format":285,"lines":351,"tokens":352,"first":353,"others":357,"copies":255,"excerpt":364,"kind":285},1208,4300,{"name":354,"start":355,"end":356},"ipc\u002Fdrawings\u002Flevel_split.svg",19,1226,[358,360,362],{"name":359,"start":355,"end":356},"ipc\u002Fdrawings\u002Flevel_split_filled.svg",{"name":361,"start":355,"end":356},"ipc\u002Fdrawings\u002Fmulti_level_filled.svg",{"name":363,"start":355,"end":356},"ipc\u002Fdrawings\u002Fmulti_level_split.svg",{"lines":365,"total":351},[366,367,345,346,347,348,368,369,370,371]," inkscape:export-xdpi=\"96\""," inkscape:export-ydpi=\"96\">","     id=\"path-effect19165\"","     is_visible=\"true\"","     weight=\"33.333333\"","     steps=\"2\"",{"format":285,"lines":373,"tokens":374,"first":375,"others":378,"copies":306,"excerpt":385,"kind":285},1266,4314,{"name":376,"start":355,"end":377},"scheduling\u002Fdrawings\u002Ffcfs.svg",1284,[379,383],{"name":380,"start":381,"end":382},"scheduling\u002Fdrawings\u002Fpsjf.svg",22,1287,{"name":384,"start":355,"end":377},"threads\u002Fdrawings\u002Fthread_nonrace_timing.svg",{"lines":386,"total":373},[387,345,346,347,348,388,369,370,371,389]," sodipodi:docname=\"fcfs.svg\">","     id=\"path-effect2726\"","     helper_size=\"0\"",{"format":285,"lines":391,"tokens":392,"first":393,"others":395,"copies":301,"kind":285},2346,8235,{"name":330,"start":331,"end":394},2383,[396],{"name":397,"start":331,"end":394},"deadlock\u002Fdrawings\u002Fdining_stalling.svg",{"format":285,"lines":399,"tokens":400,"first":401,"others":404,"copies":306,"kind":285},1041,3524,{"name":402,"start":355,"end":403},"malloc\u002Fdrawings\u002Fheap_best_fit.svg",1059,[405,407],{"name":406,"start":355,"end":403},"malloc\u002Fdrawings\u002Fheap_first_fit.svg",{"name":408,"start":355,"end":403},"malloc\u002Fdrawings\u002Fheap_worst_fit.svg",{"format":285,"lines":410,"tokens":411,"first":412,"others":415,"copies":301,"kind":285},1690,5918,{"name":330,"start":413,"end":414},64,1753,[416],{"name":417,"start":418,"end":419},"deadlock\u002Fdrawings\u002Fdining_naive.svg",44,1733,{"format":285,"lines":421,"tokens":422,"first":423,"others":426,"copies":301,"kind":285},1430,5072,{"name":424,"start":355,"end":425},"appendix\u002Fdrawings\u002Fip_datagram.svg",1448,[427],{"name":428,"start":355,"end":425},"networking\u002Fdrawings\u002Ftcp_header.svg",{"format":285,"lines":430,"tokens":431,"first":432,"others":433,"copies":301,"kind":285},1427,5052,{"name":424,"start":381,"end":425},[434],{"name":435,"start":436,"end":437},"networking\u002Fdrawings\u002Fipv6_datagram.svg",48,1474,{"format":285,"lines":439,"tokens":440,"first":441,"others":443,"copies":301,"kind":285},1267,4492,{"name":424,"start":286,"end":442},1318,[444],{"name":445,"start":381,"end":446},"ipc\u002Fdrawings\u002Fpipe_process.svg",1288,{"format":285,"lines":448,"tokens":449,"first":450,"others":452,"copies":301,"kind":285},1268,4333,{"name":380,"start":451,"end":446},21,[453],{"name":454,"start":265,"end":382},"scheduling\u002Fdrawings\u002Fsjf.svg",{"score":266,"grade":267,"size":456,"dimensions":460,"skipped":479},{"lines":457,"files":458,"class":459},18492,54,"M",[461,472],{"id":462,"source":463,"value":464,"adjusted":465,"lines":466,"halfLife":467,"formats":468,"excluded":469,"weight":308,"score":471},"duplication","jscpd",0.5,0.8,99,8.5,[292,312,298,321],[285,323,470],"data",93.5,{"id":473,"source":463,"value":474,"adjusted":475,"lines":476,"halfLife":477,"weight":308,"score":478},"complexity",81.9,75.9,15139,50,34.9,[480],{"id":481,"reason":482},"dead-code","the languages dead code reads are under 5% of the code",{"total":484,"mean":485,"files":486},3893,72.1,[487,492,497,502,507,511,516,521,526,531],{"path":488,"complexity":489,"lines":490,"bytes":491},"synchronization\u002Fsynchronization.tex",419,2395,84061,{"path":493,"complexity":494,"lines":495,"bytes":496},"ipc\u002Fipc.tex",343,1090,56311,{"path":498,"complexity":499,"lines":500,"bytes":501},"processes\u002Fprocesses.tex",320,1027,50970,{"path":503,"complexity":504,"lines":505,"bytes":506},"appendix\u002Fappendix.tex",295,1769,88886,{"path":508,"complexity":509,"lines":399,"bytes":510},"background\u002Fbackground.tex",269,49728,{"path":512,"complexity":513,"lines":514,"bytes":515},"review\u002Freview.tex",249,657,23558,{"path":517,"complexity":518,"lines":519,"bytes":520},"malloc\u002Fmalloc.tex",201,676,38251,{"path":522,"complexity":523,"lines":524,"bytes":525},"networking\u002Fnetworking.tex",192,1496,74742,{"path":527,"complexity":528,"lines":529,"bytes":530},"deadlock\u002Fdeadlock.tex",189,516,32725,{"path":532,"complexity":533,"lines":534,"bytes":535},"filesystems\u002Ffilesystems.tex",175,1358,75211,{"percentage":537,"findings":318,"files":538,"byCategory":539,"largest":542},1.69,6,[540],{"category":541,"count":318},"unused-import",[543,547,551,553,555,557,559,561,563,564],{"category":541,"path":544,"name":545,"line":546,"lines":308},"_scripts\u002Fgen_wiki.py","glob",9,{"category":541,"path":548,"name":549,"line":550,"lines":308},"_scripts\u002Fpandoc_epub_filter.py","Header",7,{"category":541,"path":548,"name":552,"line":550,"lines":308},"Link",{"category":541,"path":548,"name":554,"line":550,"lines":308},"Math",{"category":541,"path":548,"name":556,"line":550,"lines":308},"RawInline",{"category":541,"path":548,"name":558,"line":270,"lines":308},"sys",{"category":541,"path":548,"name":560,"line":546,"lines":308},"re",{"category":541,"path":562,"name":549,"line":550,"lines":308},"_scripts\u002Fpandoc_wiki_filter.py",{"category":541,"path":562,"name":558,"line":270,"lines":308},{"category":541,"path":562,"name":560,"line":546,"lines":308},{"sources":265,"lines":566,"tokens":567,"clones":301,"duplicatedLines":302,"duplicatedTokens":568,"percentage":264,"percentageTokens":569,"formats":570,"topClones":574,"generated":615},1630,6887,151,2.19,[571,572,573],{"format":298,"sources":299,"lines":300,"clones":301,"duplicatedLines":302,"percentage":303},{"format":312,"sources":313,"lines":314,"clones":315,"duplicatedLines":315,"percentage":315},{"format":321,"sources":308,"lines":307,"clones":315,"duplicatedLines":315,"percentage":315},[575,596],{"format":298,"lines":576,"tokens":577,"first":578,"others":579,"copies":301,"excerpt":583,"kind":595},18,92,{"name":548,"start":324,"end":293},[580],{"name":562,"start":581,"end":582},15,32,{"lines":584,"total":576},[585,586,587,588,589,590,591,592,593,594],"def replace_suffix(content, suffix_old, suffix_new):","    ret = content","    if content.endswith(suffix_old):","        ret = content[:-len(suffix_old)] + suffix_new","    return ret","","def deserialize(x):","    \"\"\"","    Takes a panflute element x and returns","    a basic stringified version of that element","code",{"format":298,"lines":270,"tokens":597,"first":598,"others":600,"copies":301,"excerpt":605,"kind":595},59,{"name":548,"start":293,"end":599},41,[601],{"name":602,"start":603,"end":604},"_scripts\u002Fpandoc_header_filter.py",101,108,{"lines":606,"total":270},[607,608,609,610,611,612,613,614],"if type(elem) == Image:","    # Get the number of chars for the alt tag","    alt_name = ''.join(map(deserialize, elem._content.list))","    alt_length = len(elem._content)","    # No alt means no compile","    # Accessibility by default","    if alt_length == 0 or alt_name.lower() == default_image_alt:","        raise NoAltTagException(elem.url)",{"files":315,"minified":315,"sample":616},[],"2026-10-07T06:29:42.806Z","5.4.0",{"\u002Ftrending\u002Fcs341-illinois\u002Fcoursebook":620},{"views":538,"visits":306},1795510256650]