Adding hotfixes for packages
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
19
jsx-html/examples/06.tsx
Normal file
19
jsx-html/examples/06.tsx
Normal file
@ -0,0 +1,19 @@
|
||||
/// <reference path="../jsx.d.ts" />
|
||||
import { assertEquals } from 'https://deno.land/std/testing/asserts.ts';
|
||||
|
||||
import { React } from '../mod.ts';
|
||||
|
||||
const View = () => {
|
||||
return <div innerHTML="<b>hello</b> world" />;
|
||||
};
|
||||
|
||||
if (import.meta.main) {
|
||||
(<View />).render().then(console.log);
|
||||
} else {
|
||||
Deno.test('render with array', async () => {
|
||||
assertEquals(
|
||||
await (<View />).render(),
|
||||
'<div><b>hello</b> world</div>',
|
||||
);
|
||||
});
|
||||
}
|
Reference in New Issue
Block a user