{"id":18032369,"url":"https://github.com/dmitriz/hyperscript-strict","last_synced_at":"2025-10-08T03:17:48.168Z","repository":{"id":20211772,"uuid":"89151495","full_name":"dmitriz/hyperscript-strict","owner":"dmitriz","description":"Strict API for Hyperscript Libraries","archived":false,"fork":false,"pushed_at":"2024-10-27T16:53:35.000Z","size":609,"stargazers_count":2,"open_issues_count":8,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-23T04:51:13.196Z","etag":null,"topics":["dom","hyperscript","virtual-dom"],"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/dmitriz.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":"2017-04-23T15:20:55.000Z","updated_at":"2024-05-06T12:26:28.000Z","dependencies_parsed_at":"2024-01-21T21:28:35.121Z","dependency_job_id":"f0eb2c8a-b64e-4efa-97dd-3df11eb3d049","html_url":"https://github.com/dmitriz/hyperscript-strict","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dmitriz%2Fhyperscript-strict","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dmitriz%2Fhyperscript-strict/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dmitriz%2Fhyperscript-strict/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dmitriz%2Fhyperscript-strict/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dmitriz","download_url":"https://codeload.github.com/dmitriz/hyperscript-strict/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":245791393,"owners_count":20672665,"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":["dom","hyperscript","virtual-dom"],"created_at":"2024-10-30T10:13:10.328Z","updated_at":"2025-10-08T03:17:43.147Z","avatar_url":"https://github.com/dmitriz.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# hyperscript-strict\n\n\n\nStrict API for Hyperscript Libraries\n\n## Strict Abstract Node Tree API\nAs propsed in https://github.com/hyperhype/hyperscript/issues/66#issuecomment-296449960, we implement the API\n\n### h( {tag: tag, props: props, children : children} )\n\nthat is equivalent to \n\n### h( tag : String, props : Object, children : Array )\n\n## Complete code\n\nDue to the strict nature of the API,\nthe implementation code for the extension of `h` is very short:\n\n```js\nvar isObject = val =\u003e (null != val) \u0026\u0026 ('object' == typeof val) \n\nvar extend = h =\u003e (obj, ...rest) =\u003e isObject(obj) \n\t? h(obj.tag, obj.props, obj.children.map(child =\u003e isObject(child) \n\t\t\t? extend(h)(child) \n\t\t\t: child\n\t\t))\n\t: h(obj, ...rest)\n\nmodule.exports = extend\n\n```\n\n## Run tests\n\n```sh\ngit clone https://github.com/dmitriz/hyperscript-strict\nyarn\nnpm test\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdmitriz%2Fhyperscript-strict","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdmitriz%2Fhyperscript-strict","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdmitriz%2Fhyperscript-strict/lists"}