File tree Expand file tree Collapse file tree 2 files changed +6
-7
lines changed
examples/next-with-app-dir Expand file tree Collapse file tree 2 files changed +6
-7
lines changed Original file line number Diff line number Diff line change 1- import { OrgaComponents } from '@orgajs/orgx'
1+ import type { OrgaComponents } from '@orgajs/orgx'
22import Image from 'next/image'
33
4+ // This file is required to use Orga in `app` directory.
45export function useOrgaComponents ( components : OrgaComponents ) {
6+ // Allows customizing built-in components, e.g. use next/image.
57 return {
68 ...components ,
79 img : ( props : any ) => (
8- < div >
9- < pre > { JSON . stringify ( props , null , 2 ) } </ pre >
10- < Image alt = { '' } sizes = "100vw" width = { 100 } height = { 100 } { ...props } />
11- </ div >
10+ < Image alt = { '' } sizes = "100vw" width = { 100 } height = { 100 } { ...props } />
1211 ) ,
1312 }
1413}
Original file line number Diff line number Diff line change 1616 "eslint" : " 8.39.0" ,
1717 "eslint-config-next" : " 13.3.4" ,
1818 "next" : " 13.3.2" ,
19- "react" : " 18.2.0" ,
20- "react-dom" : " 18.2.0" ,
19+ "react" : " ^ 18.2.0" ,
20+ "react-dom" : " ^ 18.2.0" ,
2121 "rehype-pretty-code" : " ^0.9.5" ,
2222 "typescript" : " 5.0.4"
2323 }
You can’t perform that action at this time.
0 commit comments