{"id":19279092,"url":"https://github.com/krasimir/prototyper","last_synced_at":"2026-03-01T17:35:43.716Z","repository":{"id":140124025,"uuid":"9751905","full_name":"krasimir/prototyper","owner":"krasimir","description":"Helpful tool for building responsive design html prototypes","archived":false,"fork":false,"pushed_at":"2013-05-21T09:33:52.000Z","size":162,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-25T16:56:09.801Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/krasimir.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-04-29T15:56:55.000Z","updated_at":"2019-07-16T07:50:16.000Z","dependencies_parsed_at":"2023-03-11T19:36:24.102Z","dependency_job_id":null,"html_url":"https://github.com/krasimir/prototyper","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/krasimir/prototyper","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krasimir%2Fprototyper","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krasimir%2Fprototyper/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krasimir%2Fprototyper/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krasimir%2Fprototyper/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/krasimir","download_url":"https://codeload.github.com/krasimir/prototyper/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/krasimir%2Fprototyper/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29976279,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-01T16:35:47.903Z","status":"ssl_error","status_checked_at":"2026-03-01T16:35:44.899Z","response_time":124,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":[],"created_at":"2024-11-09T21:13:36.103Z","updated_at":"2026-03-01T17:35:38.706Z","avatar_url":"https://github.com/krasimir.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Prototyper\n\nHelpful tool for building responsive design html prototypes. It looks like a template engine, but it's not. The main idea behind it was to be much simpler. Most of the similar libraries uses a little bit complex solutions. Also they add a lot of unnecessary markup. In *prototyper* the instructions are set in HTML comments. So even if you remove *prototyper* from your page the markup will look ok.\n\n## Usage\n\n  1. Import *prototyper.js* in your page\n  2. Attach event listeners to *prototyper* (if you need  to)\n  2. In your bootstrap script call *prototyper.run(DOMElement, data)*\n\n* check the example in */test* directory for better illustration\n\n## Commands\n\n### Including another template\nFeel free to use nested templates.\n\n\t\u003cbody\u003e\n\t\t\u003c!-- include templates/header.html --\u003e\n\t\u003c/body\u003e\n\n### Adding external data to the template\n*Prototyper* uses [mustache](http://mustache.github.io/)'s similar syntax, so you can convert the html templates easily later.\n\n\tprototyper.run(\n\t\tdocument.querySelectorAll(\"body\"),\n\t\t{\n\t\t\ttitle: \"Prototyper is really simple\",\n\t\t\tmenu: [\n\t\t\t\t{ label: \"Home\", description: \"That's the home page\"},\n\t\t\t\t{ label: \"About\", description: \"More inforomation about us\"},\n\t\t\t\t{ label: \"Contacts\", description: \"Click here to find us\"}\n\t\t\t]\n\t\t}\n\t)\n\nthen in your html\n\n\t\u003cheader\u003e\n\t\t\u003ch1\u003e{{title}}\u003c/h1\u003e\n\t\u003c/header\u003e\n\nor \n\n\t\u003cheader\u003e\n\t\t\u003cul\u003e\n\t\t\t\u003cli\u003e\u003ca href=\"#\" title=\"{{menu.description}}\"\u003e{{menu.label}}\u003c/a\u003e\u003c/li\u003e\n\t\t\t\u003cli\u003e\u003ca href=\"#\" title=\"{{menu.description}}\"\u003e{{menu.label}}\u003c/a\u003e\u003c/li\u003e\n\t\t\t\u003cli\u003e\u003ca href=\"#\" title=\"{{menu.description}}\"\u003e{{menu.label}}\u003c/a\u003e\u003c/li\u003e\n\t\t\u003c/ul\u003e\n\t\u003c/header\u003e\n\n### Events\nCurrently there is only one event to add listener to - *done*.\n\n\tPrototyper.on(\"done\", function() {\n\t\t// prototyper finishes its job\n\t});\n\n## Used resources\n\n  [http://www.w3schools.com/dom/dom_nodetype.asp](http://www.w3schools.com/dom/dom_nodetype.asp)\n  [https://github.com/padolsey/commentData/blob/master/commentdata.js](https://github.com/padolsey/commentData/blob/master/commentdata.js)\n  [http://james.padolsey.com/javascript/metadata-within-html-comments/](http://james.padolsey.com/javascript/metadata-within-html-comments/)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkrasimir%2Fprototyper","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkrasimir%2Fprototyper","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkrasimir%2Fprototyper/lists"}