{"id":19364413,"url":"https://github.com/shinyaigeek/treeche","last_synced_at":"2025-04-23T14:30:50.744Z","repository":{"id":57761791,"uuid":"489417499","full_name":"Shinyaigeek/treeche","owner":"Shinyaigeek","description":"Tree-shakable Checker for web frontend bundle size tuning","archived":false,"fork":false,"pushed_at":"2023-01-03T12:45:26.000Z","size":178,"stargazers_count":20,"open_issues_count":3,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-04-02T15:42:57.775Z","etag":null,"topics":["bundlesize","frontend","javascript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Shinyaigeek.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null}},"created_at":"2022-05-06T16:09:45.000Z","updated_at":"2023-12-22T07:26:10.000Z","dependencies_parsed_at":"2023-02-01T06:05:13.101Z","dependency_job_id":null,"html_url":"https://github.com/Shinyaigeek/treeche","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Shinyaigeek%2Ftreeche","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Shinyaigeek%2Ftreeche/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Shinyaigeek%2Ftreeche/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Shinyaigeek%2Ftreeche/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Shinyaigeek","download_url":"https://codeload.github.com/Shinyaigeek/treeche/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250451619,"owners_count":21432857,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bundlesize","frontend","javascript"],"created_at":"2024-11-10T07:37:20.309Z","updated_at":"2025-04-23T14:30:50.402Z","avatar_url":"https://github.com/Shinyaigeek.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Treeche 🌴\n\n## What is this\n\n**Tree** shakable **Che**cker.\n\ncheck your module is tree-shakable or not, in each module and reduce bundle size!!\n\n## Feature ✨\n\n- typescript support\n- you can check in each file\n- you can check with the unique entrypoint\n- glob pattern support\n- pretty diagnostics report.\n\n\n## How to use 🔧\n\n```bash\nnpm install treeche -D // TBD\ntreeche \"**/*.ts\" --excludes \"node_modules\" \"**/*.test.ts\"\n```\n\n## Example 📕\n\n```typescript\n// this is not tree-shakable because have side-effect\n\nconst currentYear = new Date().getFullYear();\n\nexport function getCurrentYear() {\n    return `Year ${currentYear}`\n}\n```\n\n```bash\ntreeche \"~~~\"\n```\n\nlog\n```bash\n\n🚨 ~/application/side_effect.ts is not tree-shakable due to the following code:\n\n\\`\\`\\`\nconst currentYear = new Date().getFullYear();\n^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n\\`\\`\\`\n```\n\nif you fix this code such above\n\n```typescript\n// this is tree-shakable because this does not have side-effect\n\nexport function getCurrentYear(currentYear: string) {\n    return `Year ${currentYear}`\n}\n```\n\nlog\n```bash\nCongratulation 🎉 All files are tree-shakeable ✨\n```\n\n## command 💻\n\n|kind|name|description|example|\n|:--:|:--:|:--:|:--:|\n|argument|inputs|input files to check tree-shakable. you can use Node glob pattern| treeche \"src/**/*.ts\"|\n|option|excludes|excludes files to filter from inputs. you can use Node glob pattern| treeche \"src/**/*.ts\" --e \"node_modules\"|\n|option|entry point|the unique entry point to check tree-shakable. if you specify input with this, treeche will bundle so you can check tree-shakable also in node_modules| treeche --entry-point ./src/main.ts|\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshinyaigeek%2Ftreeche","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fshinyaigeek%2Ftreeche","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fshinyaigeek%2Ftreeche/lists"}