{"id":13983003,"url":"https://github.com/xsip/ngx-ssr-code-remover","last_synced_at":"2025-07-21T22:32:01.312Z","repository":{"id":249507221,"uuid":"831707581","full_name":"xsip/ngx-ssr-code-remover","owner":"xsip","description":"Post processor to remove SSR Code from bundles when served","archived":false,"fork":false,"pushed_at":"2024-07-24T19:02:16.000Z","size":2158,"stargazers_count":2,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2024-08-09T05:07:50.895Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/xsip.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-07-21T11:47:15.000Z","updated_at":"2024-08-09T05:08:00.331Z","dependencies_parsed_at":"2024-08-09T05:17:56.978Z","dependency_job_id":null,"html_url":"https://github.com/xsip/ngx-ssr-code-remover","commit_stats":null,"previous_names":["xsip/ngx-ssr-code-remover"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xsip%2Fngx-ssr-code-remover","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xsip%2Fngx-ssr-code-remover/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xsip%2Fngx-ssr-code-remover/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/xsip%2Fngx-ssr-code-remover/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/xsip","download_url":"https://codeload.github.com/xsip/ngx-ssr-code-remover/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":226991556,"owners_count":17714592,"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":[],"created_at":"2024-08-09T05:01:35.691Z","updated_at":"2024-11-28T21:31:21.497Z","avatar_url":"https://github.com/xsip.png","language":"HTML","funding_links":[],"categories":["Architecture and Advanced Topics"],"sub_categories":["Server-Side Rendering"],"readme":"# ngx-ssr-code-remover\n\n**ngx-ssr-remover** will post-process your angular bundle in your express server and serve bundles with ssr code removed\n![alt text](https://github.com/xsip/ngx-ssr-code-remover/blob/main/preview.png?raw=true)\n# Setup\n``` npm i git@github.com:xsip/ngx-ssr-code-remover.git```\n\n\n Your express server should contain the following to lines.\n\n```javascript\n...\nimport {removeSsrCodeV2} from \"ngx-ssr-remover\";\n\n\n  server.set('view engine', 'html');\n  server.set('views', browserDistFolder);\n\n  // add those two lines to your express server\n  removeSsrCodeV2.removeServerCode(browserDistFolder);\n  removeSsrCodeV2.serveJsFromNoSsr(server,browserDistFolder);\n\n\n  server.get('**', express.static(browserDistFolder, {\n    maxAge: '1y',\n    index: 'index.html',\n  }));\n\n...\n```\n\nTo Automatically remove functions using the post-processor, decorate your component functions:\n\n```typescript\n...\nimport {RemoveOnServe} from \"ngx-ssr-remover/dist/decorator\";\n\n\n  @RemoveOnServe()\n  test() {\n    console.log('HI');\n  }\n\n\n\n```\n\nFeel free to write tickets when you encounter some issue.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxsip%2Fngx-ssr-code-remover","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fxsip%2Fngx-ssr-code-remover","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fxsip%2Fngx-ssr-code-remover/lists"}