NodeHive Visual Editor
NodeHive comes with a visual editor which helps content editors work with content directly from the frontend. To enable the visual editor, the frontend code needs to communicate with NodeHive.
How to configure NodeHive Visual Editor
WIP documentation
- Copy the full /nodehive folder from https://github.com/NETNODEAG/nodehive-nextjs-starter/tree/main/src/nodehive/* to [yourapp]/app/nodehive/*
- <Connector> component should be added to the global layout.tsx
- Copy https://github.com/NETNODEAG/nodehive-nextjs-starter/blob/main/src/app/api/nodehive/revalidate/route.ts to [YOURAPP]/app/api/nodehive/revalidate/route.ts
- Copy https://github.com/NETNODEAG/nodehive-nextjs-starter/blob/main/src/app/nodehive/login/page.tsx to [YOURAPP]/app/nodehive/login/page.tsx should exist
- Wrap all editable components with the respective wrapper components
- Configure form
Reference implementation
The best way to strat is using the reference implementation.
Consult https://github.com/NETNODEAG/nodehive-nextjs-starter/tree/main/src/nodehive to see how visual editor components are used.
Configure SSL on localhost
Prevent ssl errors (use only for development)
Add the following line to .env file