Newer
Older
// To be overriden in Portal
// Allow adding custom Component in project, need to add the new component type in Directus
// and register this new component here in order to use it
import React from "react"
import { IComponent } from "@onegeo-suite/gatsby-theme-onegeo"
// Import the custom Component
//// import MyComponent from "../MyComponent"
const CustomComponent = (props: IComponent) => {
const {
type,
// ...restProps
} = props
switch (type) {
// Use the 'type' added in Directus
case "mycomponent":
// Use the custom component
return <></>
}
return <></>
}
export default CustomComponent