feat: support async context
Open
- Dominant language
- TypeScript
- Stars
- 26
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
### Handling Promise Contexts
```typescript
// Promises in context will be automatically resolved
const result = await evaluate('x + y', {
x: Promise.resolve(5),
y: Promise.resolve(10)
}); // returns 15
// Handling promises returned by async functions
register('fetchData', async () => {
const response = await fetch('https://api.example.com/data');
return response.json();
});
const data = await evaluate('@fetchData()');
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.