Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

evaluating _hyperscript expressions from within JavaScript

Open
#560 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
35/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
javascript
Domain
api, web-dev

Research direction

The issue identifies window._hyperscript as the JavaScript entry point; start by tracing its dynamic-expression evaluation and the async wait and do examples described in the report. Done means the supported JavaScript-facing behavior for asynchronous expressions is established, including the returned value and completion timing, with a reproducible test or documentation.

Written by the indexing model from the issue text.

Description

I know that _hyperscript code may be part of a <script> element or an attribute of a DOM element.

But how can I evaluate dynamic _hyperscript expressions from within JavaScript (e.g., as part of a REPL)?

window._hyperscript seems to be a function which principally does what I need - but it does not return a Promise in case of asynchronous code (e.g., wait 2s).

And (even more surprising), evaluating async wait 2s log "Hi!" return "Hello, World!" immediately returns "Hello, World!" but waits 2s before logging "Hi!" - what I definitely do not understand...

Thus, how can I evaluate (potentially asynchronous) dynamic(!) _hyperscript expressions from within JavaScript?

Amendment: async do ... end returns undefined like not using async at all

Dominant language
JavaScript
Stars
3.8k
Forks
171
PR merge metrics
No merged PRs in 30d

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from bigskysoftware/_hyperscript

All issues in bigskysoftware/_hyperscript

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.