{"id":13668269,"url":"https://github.com/readium/ts-toolkit","last_synced_at":"2026-04-23T09:04:00.577Z","repository":{"id":40506095,"uuid":"220052920","full_name":"readium/ts-toolkit","owner":"readium","description":"A toolkit for ebooks, audiobooks and comics written in Typescript","archived":false,"fork":false,"pushed_at":"2025-08-26T13:29:41.000Z","size":857,"stargazers_count":93,"open_issues_count":45,"forks_count":19,"subscribers_count":15,"default_branch":"develop","last_synced_at":"2025-08-26T18:18:18.912Z","etag":null,"topics":["audiobooks","cbr","cbz","ebook","ebook-reader","ebooks","epub","reading","readium","typescript","webapp"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/readium.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":"2019-11-06T17:28:58.000Z","updated_at":"2025-08-16T05:03:24.000Z","dependencies_parsed_at":"2023-11-06T12:43:13.237Z","dependency_job_id":"a668d4d4-e4fe-4a8c-83fd-e00009923c3a","html_url":"https://github.com/readium/ts-toolkit","commit_stats":{"total_commits":139,"total_committers":9,"mean_commits":"15.444444444444445","dds":0.539568345323741,"last_synced_commit":"d89aa8d01c01973a0fc173bda5cfe29e5dd4b045"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/readium/ts-toolkit","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/readium%2Fts-toolkit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/readium%2Fts-toolkit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/readium%2Fts-toolkit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/readium%2Fts-toolkit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/readium","download_url":"https://codeload.github.com/readium/ts-toolkit/tar.gz/refs/heads/develop","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/readium%2Fts-toolkit/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":272988919,"owners_count":25026961,"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-08-31T02:00:09.071Z","response_time":79,"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":["audiobooks","cbr","cbz","ebook","ebook-reader","ebooks","epub","reading","readium","typescript","webapp"],"created_at":"2024-08-02T08:00:28.547Z","updated_at":"2026-04-23T09:04:00.571Z","avatar_url":"https://github.com/readium.png","language":"TypeScript","funding_links":[],"categories":["Toolkits"],"sub_categories":[],"readme":"# Readium Web\n\nNext generation SDK for publications in Web Apps\n\n## Usage\n\nThree packages are made available by this repository, which are published on NPM.\nThey are:\n- [@readium/shared](https://www.npmjs.com/package/@readium/shared)\n- [@readium/navigator-html-injectables](https://www.npmjs.com/package/@readium/navigator-html-injectables)\n- [@readium/navigator](https://www.npmjs.com/package/@readium/navigator)\n\n# Development\n\nYou need `pnpm` installed as this is a monorepo using workspaces.\n\nTo install pnpm using node:\n\n```sh\nnpm install -g pnpm\n```\n\nNote there are [several other options](https://pnpm.io/installation) if needed.\n\nTo install all dependencies:\n\n```sh\npnpm install\n```\n\nThen workspaces should be all set up and you can build them from their directory in the following order:\n\n1. shared\n2. navigator-html-injectables\n3. navigator\n\n## Workspaces\n\n- [Shared](./shared/): shared models to be used across other Readium projects and implementations in Typescript.\n- [Navigator](./navigator/): a navigator for web platforms based on the readium Navigator spec.\n- [Navigator-html-injectables](./navigator-html-injectables/): provides access and control over a resource from a navigator on any modern browser or embedded browser frame.\n\n## Local Development in a test app\n\nIf you want to develop locally, you have two simpler options:\n\n- Using the `file:` syntax\n- Using `pnpm link`\n\n### Using file: syntax\n\nYou can use the `file:` syntax to link the packages to your project. This is useful for testing changes in a real application.\n\n```json\n{\n  \"dependencies\": {\n    \"@readium/shared\": \"file:path/to/ts-toolkit/shared\",\n    \"@readium/navigator-html-injectables\": \"file:path/to/ts-toolkit/navigator-html-injectables\",\n    \"@readium/navigator\": \"file:path/to/ts-toolkit/navigator\"\n  }\n}\n```\n\nThen run:\n\n```sh\npnpm install\n```\n\nYour modifications to the packages will now be reflected in your project, although you may have to restart your development server to see the changes, or reload your IDE window to pick up the type changes.\n\n### Using pnpm link\n\nWhen developing locally, you can [link these packages to your project](https://pnpm.io/cli/link) for testing changes in a real application. Here's how to set it up:\n\n1. First, build all packages in the correct order:\n\n```sh\ncd shared \u0026\u0026 pnpm build \u0026\u0026 cd ..\ncd navigator-html-injectables \u0026\u0026 pnpm build \u0026\u0026 cd ..\ncd navigator \u0026\u0026 pnpm build \u0026\u0026 cd ..\n```\n\n2. Make the packages available globally for linking:\n\n```sh\ncd shared \u0026\u0026 pnpm link --global \u0026\u0026 cd ..\ncd navigator-html-injectables \u0026\u0026 pnpm link --global \u0026\u0026 cd ..\ncd navigator \u0026\u0026 pnpm link --global \u0026\u0026 cd ..\n```\n\nThen proceed with either Method 1 or Method 2 below.\n\n#### Method 1: Adding packages to package.json\n\nIf you don't already have the packages in your project's dependencies, add the packages to your `package.json`:\n\n```json\n{\n  \"dependencies\": {\n    \"@readium/shared\": \"link:../ts-toolkit/shared\",\n    \"@readium/navigator-html-injectables\": \"link:../ts-toolkit/navigator-html-injectables\",\n    \"@readium/navigator\": \"link:../ts-toolkit/navigator\"\n  }\n}\n```\n\nThen install the dependencies:\n\n```sh\n# In your project directory\npnpm install\n```\n\nYou can now modify the source code of the linked package, and the changes will be reflected in your project on re-build.\n\n#### Method 2: Linking existing dependencies\n\nIf you already have the packages in your project's dependencies (e.g., `\"@readium/shared\": \"^2.0.0\"`):\n\n\nIn your project directory, link each package:\n\n```sh\n# In your project directory\npnpm link @readium/shared @readium/navigator-html-injectables @readium/navigator\n```\n\nYou can now modify the source code of the linked package, and the changes will be reflected in your project on re-build.\n\nWhen you're done testing and want to unlink the packages and restore the original versions:\n\n```sh\n# In your project directory\npnpm unlink @readium/shared @readium/navigator-html-injectables @readium/navigator\npnpm install\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freadium%2Fts-toolkit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Freadium%2Fts-toolkit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Freadium%2Fts-toolkit/lists"}