Usage outside antd
panjiesw opened this issue · 1 comments
Hi there just found this awesome plugin when trying to solve runtime theming with antd.
If I have libraries which use antd components, and follow the same theming solution as antd (the library components can be passed in babel-plugin-import to have its less files loaded in compilation), can the library also be themed using this? Or is this hardcoded to only work for antd components?
I want to provide my library consumer with the same theming ability provided by using this plugin, if possible.
Thanks @panjiesw. The library is hard-coded for antd
: it explicitly imports the default.less
style file inside the antd
package, compiles it, and reads the variables for use in SASS. Please feel free to ask questions about the source if you decide to fork the project and modify it for your use case.