{"id":15040684,"url":"https://github.com/cryrivers/manta-style","last_synced_at":"2025-09-19T17:53:02.612Z","repository":{"id":40790657,"uuid":"140395761","full_name":"Cryrivers/manta-style","owner":"Cryrivers","description":"🚀 The futuristic API Mock Server for Frontend","archived":false,"fork":false,"pushed_at":"2023-06-30T16:49:32.000Z","size":1312,"stargazers_count":42,"open_issues_count":12,"forks_count":5,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-06T17:37:16.145Z","etag":null,"topics":["fakerjs","mock-server","typescript"],"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/Cryrivers.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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":"2018-07-10T07:42:43.000Z","updated_at":"2023-05-01T11:14:17.000Z","dependencies_parsed_at":"2024-08-09T13:21:46.993Z","dependency_job_id":null,"html_url":"https://github.com/Cryrivers/manta-style","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cryrivers%2Fmanta-style","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cryrivers%2Fmanta-style/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cryrivers%2Fmanta-style/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Cryrivers%2Fmanta-style/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Cryrivers","download_url":"https://codeload.github.com/Cryrivers/manta-style/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248830828,"owners_count":21168353,"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":["fakerjs","mock-server","typescript"],"created_at":"2024-09-24T20:44:55.364Z","updated_at":"2025-09-19T17:52:57.567Z","avatar_url":"https://github.com/Cryrivers.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"./resources/manta-style.svg\" height=\"100\"/\u003e\n\u003c/p\u003e\n\u003cp align=\"center\"\u003e🚀 The futuristic API Mock Server for Frontend\u003c/p\u003e\n\u003cp align=\"center\"\u003e\u003ca href=\"https://circleci.com/gh/Cryrivers/manta-style\"\u003e\u003cimg src=\"https://img.shields.io/circleci/project/github/Cryrivers/manta-style.svg?style=flat-square\" alt=\"CircleCI\" /\u003e\u003c/a\u003e \u003ca href=\"https://codecov.io/gh/Cryrivers/manta-style/\"\u003e\u003cimg src=\"https://img.shields.io/codecov/c/github/Cryrivers/manta-style.svg?style=flat-square\" alt=\"Codecov\" /\u003e\u003c/a\u003e \u003ca href=\"https://github.com/Cryrivers/manta-style/blob/master/LICENSE\"\u003e\u003cimg src=\"https://img.shields.io/github/license/Cryrivers/manta-style.svg?style=flat-square\" alt=\"GitHub\" /\u003e\u003c/a\u003e \u003cimg src=\"https://img.shields.io/npm/v/@manta-style/core.svg?style=flat-square\" alt=\"version\" /\u003e \u003ca href=\"https://lernajs.io/\"\u003e\u003cimg src=\"https://img.shields.io/badge/maintained%20with-lerna-cc00ff.svg?style=flat-square\" alt=\"lerna\" /\u003e\u003c/a\u003e\u003c/p\u003e\n\n---\n\n**✨ UPDATE:**\n\nWhile Manta Style is designed to be a mock server that converts type definitions into mock data. The core of Manta Style compiles definitions and makes them usable at JavaScript runtime. The runtime also supports input formatting and validation other than mocking data.\n\nFor more tools built with Manta Style core runtime, please check out [Tools](#tools).\n\n---\n\nCheck out the [Quick Start](./documentation/QuickStart.md) page for a quick overview.\n\n- [Installation](./documentation/Installation.md)\n- [Quick Start](./documentation/QuickStart.md)\n- [Examples (Recommended)](./documentation/Examples.md)\n- [Usage](./documentation/Usage.md)\n- [Plugins](./documentation/Plugins.md)\n\n## Motivation\n\n[Manta Style](https://github.com/Cryrivers/manta-style/issues/1) generates \"real\" _(enough)_ mock data from your type definitions.\n\nWith _Manta Style_, you can start implementing feature once your data schema is defined.\nBut _Manta Style_ is more than just that.\n\n### Generates mock data directly from your type declarations\n\nManta Style officially supports [TypeScript](https://www.typescriptlang.org) and [Flow](http://flowtype.org/) at the moment.\n\n\u003c!-- some more words goes here @TODO wgao19 --\u003e\n\n### Mock data with respect to real world scenario such as past dates, addresses, names\n\n```ts\ninterface User {\n  /**\n   * @faker {{internet.userName}}\n   */\n  userName: string; // Amina.Langosh49\n\n  /**\n   * @faker date.past\n   */\n  birthday: number; // 1529370938452\n\n  /**\n   * @example Croatia\n   */\n  country: string; // Croatia\n}\n```\n\n### Mock conditions specific to your type definitions\n\n```ts\ntype WithResponseSuccess\u003cT\u003e = {\n  status: 'ok';\n  data: T;\n};\n\ntype WithResponseFailure = {\n  status: 'error';\n  /**\n   * @example Bad Request\n   */\n  message: string;\n};\n\ntype WithResponse\u003cT\u003e = WithResponseSuccess\u003cT\u003e | WithResponseFailure;\n```\n\nManta Style will generate either the error case or the normal case according to your declarations.\nAlready have your list of error conditions and messages well-defined with your back end? You are in the luck! Manta Style will generate those cases for you just like in real world.\n\nThis also gives us one more motivation to fine-tune the typing to our codebase.\n\n### Fix a test case like a snapshot.\n\nImplementing boundary cases has been hair pulling. With Manta Style you can supply a snapshot and have it returned every time until you finish.\n\n### ... and more\n\nNeed more feature? [Create an issue](https://github.com/Cryrivers/manta-style/issues/new/choose) and let us know how Manta Style can help you.\n\n## Contributing\n\n### Getting Started\n\n```sh\nnpm install\nnpm run bootstrap\nnpm run build\n```\n\n## Tools\n\n- [Magic Type](https://github.com/Cryrivers/magic-type), a CLI tool that compiles TypeScript definitions to type objects runnable at JavaScript runtime.\n\n## Acknowledgments\n\n- [Zhongliang Wang](https://github.com/Cryrivers) for original idea, architecture design, initial implementation of runtime and transformers.\n- [Tan Li Hau](https://github.com/tanhauhau) for the design and implementation of selective mocking, plugin system, FlowType support and many official plugins.\n- [Jennie Ji](https://github.com/JennieJi) for implementation of live-reload feature.\n- [Wei Gao](https://github.com/wgao19) for brilliant documentation.\n\n## License\n\nManta Style is [MIT licensed](https://github.com/Cryrivers/manta-style/blob/master/LICENSE)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcryrivers%2Fmanta-style","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcryrivers%2Fmanta-style","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcryrivers%2Fmanta-style/lists"}