Background
It is impossible to use ketcher in SSR applications because of errors. The reason is that ketcher uses browser APIs, such a "window" object, which are not supported on server side.
Solution
Create example of SSR application which uses ketcher (similar what we have in /example folder). Wrap all usages of unsupported APIs into conditions to exclude it from execution on server side. Probably better option is to wrap the initialisation code to have this check in one place only.
Additional context
It was found that Raphaeljs library(used for render in molecules mode) uses window object.
Background It is impossible to use ketcher in SSR applications because of errors. The reason is that ketcher uses browser APIs, such a "window" object, which are not supported on server side.
Solution Create example of SSR application which uses ketcher (similar what we have in /example folder). Wrap all usages of unsupported APIs into conditions to exclude it from execution on server side. Probably better option is to wrap the initialisation code to have this check in one place only.
Additional context It was found that Raphaeljs library(used for render in molecules mode) uses window object.