{"id":15379586,"url":"https://github.com/blond/detemplate","last_synced_at":"2025-04-09T03:16:23.129Z","repository":{"id":81510529,"uuid":"69175159","full_name":"blond/detemplate","owner":"blond","description":":bookmark: Parse string by template","archived":false,"fork":false,"pushed_at":"2016-09-25T16:12:12.000Z","size":3,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-02-14T21:31:20.633Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","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/blond.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}},"created_at":"2016-09-25T16:08:47.000Z","updated_at":"2016-09-25T22:29:58.000Z","dependencies_parsed_at":null,"dependency_job_id":"97ac1034-6755-49aa-b4e0-b426366dd686","html_url":"https://github.com/blond/detemplate","commit_stats":{"total_commits":2,"total_committers":1,"mean_commits":2.0,"dds":0.0,"last_synced_commit":"58077c0f3c99c9479345b41cd89b83f7e9031d95"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blond%2Fdetemplate","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blond%2Fdetemplate/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blond%2Fdetemplate/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/blond%2Fdetemplate/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/blond","download_url":"https://codeload.github.com/blond/detemplate/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247968377,"owners_count":21025823,"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-10-01T14:19:25.022Z","updated_at":"2025-04-09T03:16:23.113Z","avatar_url":"https://github.com/blond.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"detemplate\n==========\n\n[![NPM Status][npm-img]][npm]\n[![Travis Status][test-img]][travis]\n[![Coverage Status][coverage-img]][coveralls]\n[![Dependency Status][david-img]][david]\n\n[npm]:          https://www.npmjs.org/package/detemplate\n[npm-img]:      https://img.shields.io/npm/v/detemplate.svg\n\n[travis]:       https://travis-ci.org/blond/detemplate\n[test-img]:     https://img.shields.io/travis/blond/detemplate.svg?label=tests\n\n[coveralls]:    https://coveralls.io/r/blond/detemplate\n[coverage-img]: https://img.shields.io/coveralls/blond/detemplate.svg\n\n[david]:        https://david-dm.org/blond/detemplate\n[david-img]:    http://img.shields.io/david/blond/detemplate.svg?style=flat\n\nParse string by template.\n\nInstall\n-------\n\n```\n$ npm install --save detemplate\n```\n\nUsage\n-----\n\n```js\nconst detemplate = require('detemplate');\n\nconst template = '${name} ${middlename} «${nickname}» ${surname}';\nconst parseNames = detemplate.compile(template);\n\nparseNames('Bartholomew Jo-Jo «Bart» Simpson');\n\n// Ay, caramba! Eat my shorts!\n//\n// ➜ {\n//     name: 'Bartholomew',\n//     surname: 'Simpson',\n//     middlename: 'Jo-Jo',\n//     nickname: 'Bart'\n// }\n```\n\nAPI\n---\n\n### compile(template)\n\nCreates a compiled function that can extract data properties from place holders (ES template literal delimiters).\n\n### template\n\nType: `string`\n\nThe string that contains place holders (ES template literal delimiters). These are indicated by the Dollar sign and curly braces (`${placeHolder}`).\n\nLicense\n-------\n\nMIT © [Andrew Abramov](https://github.com/blond)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblond%2Fdetemplate","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fblond%2Fdetemplate","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fblond%2Fdetemplate/lists"}