Fragment
virtual:/play/fragment.tsx
import { fragment } from '@weftjs/core'
interface Props { label: string; count: number }
export default fragment(({ label, count }: Props) => (
<span class="pill">
{label} <b>{count}</b>
</span>
))
While you type
a scan, not the compiler
- Reads
- nothing
- Cache class
static
Elision needs a checker, and a virtual file set has no directory to open — so the compile beside this escapes every hole. On a real file the ones marked none would not be escaped.