{"id":16859644,"url":"https://github.com/dotcypress/compile-template","last_synced_at":"2025-06-16T22:06:41.424Z","repository":{"id":57204659,"uuid":"70977503","full_name":"dotcypress/compile-template","owner":"dotcypress","description":"📠 Micro templates for Node.js","archived":false,"fork":false,"pushed_at":"2022-11-11T05:33:01.000Z","size":7,"stargazers_count":4,"open_issues_count":3,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-05-16T02:06:02.414Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","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/dotcypress.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}},"created_at":"2016-10-15T09:01:18.000Z","updated_at":"2023-03-04T06:17:20.000Z","dependencies_parsed_at":"2023-01-22T00:16:15.812Z","dependency_job_id":null,"html_url":"https://github.com/dotcypress/compile-template","commit_stats":null,"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/dotcypress/compile-template","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dotcypress%2Fcompile-template","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dotcypress%2Fcompile-template/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dotcypress%2Fcompile-template/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dotcypress%2Fcompile-template/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dotcypress","download_url":"https://codeload.github.com/dotcypress/compile-template/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dotcypress%2Fcompile-template/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":260134164,"owners_count":22963857,"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-13T14:19:02.950Z","updated_at":"2025-06-16T22:06:41.397Z","avatar_url":"https://github.com/dotcypress.png","language":"JavaScript","readme":"[![NPM Version](https://img.shields.io/npm/v/compile-template.svg?style=flat-square)](https://www.npmjs.com/package/compile-template)\n[![node](https://img.shields.io/node/v/compile-template.svg?style=flat-square)](https://www.npmjs.com/package/compile-template)\n[![Build Status](https://img.shields.io/travis/dotcypress/compile-template.svg?branch=master\u0026style=flat-square)](https://travis-ci.org/dotcypress/compile-template)\n[![js-standard-style](https://img.shields.io/badge/code%20style-standard-brightgreen.svg?style=flat-square)](http://standardjs.com/)\n\n# compile-template\n\u003e 📠 Micro templates for Node.js\n\n\u003e `js template literals` + `node vm` = `profit`\n\n**Captain obvious alert**: 🚨 The node vm module is not a security mechanism. Do not use untrusted code in templates.\n\n### Installation\n\nInstall from NPM:\n\n```js\n$ npm install compile-template --save\n```\n\n**Note**: `compile-template` requires Node `4.0.0` or later\n\n### Example\n\n```js\nconst compile = require('compile-template')\n\nconst template = compile('foo=${41+value}')\nconst string = template({value: 1})\nassert(string === 'foo=42')\n\nconst template = compile('foo=${41+value}', {value: 1})\nassert(template() === 'foo=42')\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdotcypress%2Fcompile-template","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdotcypress%2Fcompile-template","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdotcypress%2Fcompile-template/lists"}