-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Don't output preview containers what also affects live #5
Comments
I agree that only rendering the |
Hi, Thanks for reporting and sorry for the delayed response, somehow I didn't receive any notifications on new issues. I fully agree that this can indeed be optimized. I'll make some adjustments. Are you willing to test out the adjustments when I publish a new RC/beta tag? Best, |
Hi @maapteh and @TimoWestland , I have made some modifications to the container and container-item classes so they no longer insert CMS-required markup outside of preview. See 8e9d79b. You can test the changes in the latest beta tag (0.3.0-rc1), see: https://www.npmjs.com/package/bloomreach-experience-react-sdk/v/0.3.0-rc1 Let me know if this fixes it! Best, |
Hi Robbert, I ended up writing my own HOC because in my situation the PageModel is not the same as Hippo anymore, maybe it can "help" your 'if else' stuff a little more nicer. Thanks for you changes and response anyway.
consumer: |
Thanks for sharing! I'm closing this issue assuming this fixes it. Anyone, feel free to reopen if the solution is not working or causing issues. |
Hi, if i look at for example 'CmsContainer' i see a lot of code which also affects live output but also things which can be optimized. I don't really like the extra div's its creating for example (for live output, less is more), and also 'preview' is passed inside this component while lot of it could be done outside.
https://github.com/bloomreach/experience-react-sdk/blob/master/src/cms-components/core/container.js#L6
when i create something like this (without looping just an example of what i mean):
I have no containers as output which is only needed for PREVIEW. Also I don't need to go trough functions which are only needed when in preview mode (faster). I don't need to have reference.
I like the sdk, don't get me wrong but i would just to point out some things I dislike about it but will be happy to work trough them if my company decides to take this route.
The text was updated successfully, but these errors were encountered: