Closed sapegin closed 6 years ago
It might be easier to test this against the simple demo at antwar repository. I wonder if the build process works against style extraction here. It generates a big site bundle before generating individual pages.
The problem is it doesn’t work with dynamic styles, so even ${t.space.xl}
doesn’t work. I need to investigate what option we have.
Ah, right. They suggest using CSS variables for dynamic bits.
But they are not dynamic from the run time point of view ;-) I guess we can make another plugin to inline theme variables. Another problem is props — we’ll probably have to split these components into multiple.
Now I need to solve the modifiers issue (<Panel prev>
, <Panel next>
).
@bebraw How do you like it now? Static extraction works fine as long as you don’t use any dynamic content like functions. But you may use theme
.
I’ll extract Babel plugin to a separate package.
I guess it’s done and works quite well. What do you think?
Really nice work. I think eventually we should push components like this to https://github.com/survivejs-sites/components and implement a style guide. Nice, isolated, and reusable.
Yeah, that wood be good ;-)
I’m still trying to understand how to make styles extraction work ;-/