prep icon indicating copy to clipboard operation
prep copied to clipboard

Does it work for Web Components (native, Polymer)?

Open motss opened this issue 8 years ago • 5 comments

It'd be nice if Web Components would be rendered.

motss avatar Jul 28 '17 03:07 motss

I suppose yes, it is based on headless chrome

stereobooster avatar Sep 29 '17 17:09 stereobooster

I think it is more complicated than that. Shadow DOM is the biggest issue if I'm not mistaken. Look into this: https://github.com/skatejs/ssr/blob/master/README.md and this: https://github.com/Polymer/polymer/issues/3955

I don't think SSR for web components is fully possible yet.

lastmjs avatar Oct 24 '17 22:10 lastmjs

@motss do you have example of small website with components? I would like to run some tests

stereobooster avatar Oct 24 '17 22:10 stereobooster

@stereobooster, here are two examples with web components: https://github.com/Polymer/shop

https://github.com/PolymerElements/polymer-starter-kit

toshovski avatar Nov 05 '17 00:11 toshovski

Still, haven't a chance to look into it. As far as I understand you can prerender Shadow DOM to actual DOM, like rendertron does, but to there is no easy way to prerender and rehydrate. Skate.js, for example, prerenders shadow dom and serializes it to JS

stereobooster avatar Dec 30 '17 23:12 stereobooster