///
import { assertEquals } from 'https://deno.land/std/testing/asserts.ts';
import { delay } from 'https://deno.land/std/async/delay.ts';
import { React } from '../mod.ts';
const Title = async () => {
await delay(100);
return
title{ await delay(100) }
;
};
const View = () => (
);
if (import.meta.main) {
().render().then(console.log);
} else {
// Run test
Deno.test('render title', async () => {
assertEquals(await ().render(), 'title
');
});
Deno.test('render view', async () => {
assertEquals(await ().render(), 'title
');
});
}