Package Exports
- @cloudcannon/react-connector
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@cloudcannon/react-connector) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
CloudCannon React Connector
Using a React based SSG? Want to see give your editors a live visual editing experience? Use the React Connector and connect CloudCannon.
Installation
npm i @cloudcannon/react-connectorNext JS Integration
Update the code in pages/_app.jsx from:
export default function App({ Component, pageProps }) {
return <Component {...pageProps} />
}to:
import { CloudCannonConnect } from '@cloudcannon/react-connector'
export default function App({ Component, pageProps }) {
const AppComponent = CloudCannonConnect(Component);
return <AppComponent {...pageProps}/>
}In CloudCannon will now push through new page props from your editors updates.