{"id":17651748,"url":"https://github.com/diegovictor/tsc-path-replacer","last_synced_at":"2025-09-26T13:00:09.423Z","repository":{"id":61043250,"uuid":"540973571","full_name":"DiegoVictor/tsc-path-replacer","owner":"DiegoVictor","description":"NPM Package. Resolve imports/requires alias according to tsconfig paths","archived":false,"fork":false,"pushed_at":"2024-01-10T19:33:25.000Z","size":236,"stargazers_count":5,"open_issues_count":1,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-08-28T16:44:23.829Z","etag":null,"topics":["alias","aliases","import","javascript","js","node","nodejs","npm","npm-package","package","paths","require","ts","tsc","tsconfig","typescript"],"latest_commit_sha":null,"homepage":"https://www.npmjs.com/package/@diegovictor/tsc-path-replacer","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/DiegoVictor.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":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2022-09-24T21:34:59.000Z","updated_at":"2024-10-30T16:18:31.000Z","dependencies_parsed_at":"2024-01-10T20:39:35.720Z","dependency_job_id":"1a4ea7d2-6b75-4899-995d-0dc1769cd805","html_url":"https://github.com/DiegoVictor/tsc-path-replacer","commit_stats":{"total_commits":94,"total_committers":1,"mean_commits":94.0,"dds":0.0,"last_synced_commit":"5ac4a0f4d79da5b3616e4e0e266bb43e4c54737e"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/DiegoVictor/tsc-path-replacer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DiegoVictor%2Ftsc-path-replacer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DiegoVictor%2Ftsc-path-replacer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DiegoVictor%2Ftsc-path-replacer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DiegoVictor%2Ftsc-path-replacer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/DiegoVictor","download_url":"https://codeload.github.com/DiegoVictor/tsc-path-replacer/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/DiegoVictor%2Ftsc-path-replacer/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":277081049,"owners_count":25757340,"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","status":"online","status_checked_at":"2025-09-26T02:00:09.010Z","response_time":78,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["alias","aliases","import","javascript","js","node","nodejs","npm","npm-package","package","paths","require","ts","tsc","tsconfig","typescript"],"created_at":"2024-10-23T11:43:29.271Z","updated_at":"2025-09-26T13:00:09.402Z","avatar_url":"https://github.com/DiegoVictor.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# tsc-path-replacer\n[![npm](https://img.shields.io/npm/v/@diegovictor/tsc-path-replacer?style=flat-square)](https://www.npmjs.com/package/@diegovictor/tsc-path-replacer)\n[![eslint](https://img.shields.io/badge/eslint-8.24.0-4b32c3?style=flat-square\u0026logo=eslint)](https://eslint.org/)\n[![prettier](https://img.shields.io/badge/prettier-2.7.1-F7B93E?style=flat-square\u0026logo=prettier)](https://prettier.io/)\n[![airbnb-style](https://flat.badgen.net/badge/style-guide/airbnb/ff5a5f?icon=airbnb)](https://github.com/airbnb/javascript)\n[![typescript](https://img.shields.io/badge/typescript-4.8.3-3178c6?style=flat-square\u0026logo=typescript)](https://www.typescriptlang.org/)\n[![MIT License](https://img.shields.io/badge/license-MIT-green?style=flat-square)](https://raw.githubusercontent.com/DiegoVictor/tsc-path-replacer/main/LICENSE)\n[![PRs Welcome](https://img.shields.io/badge/PRs-welcome-brightgreen.svg?style=flat-square)](http://makeapullrequest.com)\n\nResolve imports/requires alias according to tsconfig paths. It tries use more resources provided by Node.js, like, asynchronous methods, paralelism and a simple memory cache. (Also, it works on windows!)\n\n### Examples\n```js\n// ./src/controllers/user/index.js\n\n// this import:\nimport userService from '@services/user/getUsers';\n// will be replaced by:\nimport userService from '../../services/user/getUsers';\n```\n\nUsing `require`:\n```js\n// ./src/controllers/user/index.js\n\nconst userService = require('@services/user/getUsers');\nconst userService = require('../../services/user/getUsers');\n```\n\nThe biggest difference from this package to another similar ones is the huge usage of the Node.js asynchronous APIs and paralelism (up to 5 files are processed at the same time).\n\n## Table of Contents\n* [Installing](#installing)\n* [Usage](#usage)\n* [Inspired by](#inspired-by)\n\n# Installing\nJust run:\n```\nnpm install --save-dev @diegovictor/tsc-path-replacer\n```\nOr simply:\n```\nyarn add -D @diegovictor/tsc-path-replacer\n```\n\n# Usage\nRegister on your build script:\n```json\n\"scripts\": {\n  \"build\": \"tsc --project tsconfig.json \u0026\u0026 tsc-path-replacer tsconfig.json\",\n}\n```\n\n# Inspired by\n[tsconfig-replace-paths](https://github.com/jonkwheeler/tsconfig-replace-paths)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdiegovictor%2Ftsc-path-replacer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdiegovictor%2Ftsc-path-replacer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdiegovictor%2Ftsc-path-replacer/lists"}