{"id":18609658,"url":"https://github.com/unlight/typescript-service","last_synced_at":"2025-04-10T22:31:40.105Z","repository":{"id":57383926,"uuid":"139318152","full_name":"unlight/typescript-service","owner":"unlight","description":"Language service which helps to get diagnostic messages from typescript source files.","archived":false,"fork":false,"pushed_at":"2019-01-17T09:06:32.000Z","size":20,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2024-10-31T17:33:59.371Z","etag":null,"topics":["typescript","typescript-api","typescript-compiler","typescript-helpers","typescript-wrapper"],"latest_commit_sha":null,"homepage":null,"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/unlight.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-07-01T10:01:33.000Z","updated_at":"2023-10-16T11:27:11.000Z","dependencies_parsed_at":"2022-09-14T00:21:20.713Z","dependency_job_id":null,"html_url":"https://github.com/unlight/typescript-service","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Ftypescript-service","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Ftypescript-service/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Ftypescript-service/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/unlight%2Ftypescript-service/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/unlight","download_url":"https://codeload.github.com/unlight/typescript-service/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223449848,"owners_count":17146984,"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":["typescript","typescript-api","typescript-compiler","typescript-helpers","typescript-wrapper"],"created_at":"2024-11-07T03:06:51.260Z","updated_at":"2024-11-07T03:06:51.911Z","avatar_url":"https://github.com/unlight.png","language":"TypeScript","readme":"# typescript-service\nLanguage service which helps to get diagnostic messages from typescript source files.\n\n## INSTALL\n```\nnpm install --save-dev typescript-service\n```\n\n## USAGE\n```ts\nimport { createService } from 'typescript-service';\n\nconst service = createService({ configFile, compilerOptions });\nconst diagnostics = service.getDiagnostics(fileName);\n```\n\n## API\n\n#### createService({ configFile: string, compilerOptions?: ts.CompilerOptions })\n* `configFile` (required, string) Path to tsconfig.json file\n* `compilerOptions` (optional, Object) Compiler options to overwrite defined in tsconfig.json\n\nReturns object with properties which are functions:\n\n##### getSourceFile({ fileName: string, sourceText?: string })\nUpdate (add) information about file in typescript service.\n* `fileName` (required, string) Path to typescript file\n* `sourceText` (optional, string) File content of this file\n\n##### getDiagnostics: (fileName: string, sourceText?: string): Array\u003cts.DiagnosticWithLocation\u003e\nGet diagnostic messages for `fileName`\n* `fileName` (required, string) Path to typescript file\n* `sourceText` (optional, string) If path outside of scope defined in tsconfig you need provide `sourceText`\n\n##### getProgram(): ts.Program\nGet `ts.Program`\n\n## CHANGELOG\nSee [CHANGELOG.md](CHANGELOG.md)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funlight%2Ftypescript-service","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Funlight%2Ftypescript-service","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Funlight%2Ftypescript-service/lists"}