Skip to content

Commit 51d4066

Browse files
committed
[readme] add documentation for <Bundle>
1 parent 0ce9aac commit 51d4066

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -413,4 +413,9 @@ function App() {
413413

414414
Renders a `<body>` element.
415415

416+
#### `<Bundle>`
417+
418+
Renders the necessary `<link>` / `<style>`, and `<script>` elements to import generated JavaScript and CSS. Use this if
419+
you do not want to manage them yourself and also do not want to use [`<Head>`](#head).
420+
416421
### Islands

src/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@ export {Fragment} from './jsx/factory'
77
export {default as Html} from './jsx/dom/builtins/Html'
88
export {default as Head} from './jsx/dom/builtins/Head'
99
export {default as Body} from './jsx/dom/builtins/Body'
10+
export {default as Bundle} from './jsx/dom/builtins/Bundle'

src/jsx/dom/builtins/Head.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
import State from '../../../state/state'
2-
import {Volume} from 'memfs/lib/volume'
3-
import Bundle from './Bundle'
1+
import {Bundle} from '#cherry-soda'
42

53
export default function Head({children, ...props}: JSX.IntrinsicElements['head']) {
64
const charset = children.find(<meta charSet/>) ?? <meta charSet={'utf-8'}/>

0 commit comments

Comments
 (0)