dva project demo?
liujunyi opened this issue · comments
Use https://github.com/mzohaibqc/antd-theme-generator for non create-create-react projects. It's pretty simple
<script> window.less = { async: false, env: 'production' }; </script> <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/less.js/2.7.2/less.min.js"></script> Now you can update colors by updating less avriables like thisUse https://github.com/mzohaibqc/antd-theme-generator for non create-create-react projects. It's pretty simple
thank you! I try your code,it's ok in dev but it's failed after build. lost some less files.
in my code ,i did the following things.
window.less.modifyVars({
'@primary-color': '#0035ff'
})
@liujunyi Can you create a repo with sample code so that I can't look into that. This information is not sufficient to determine what's wrong. :)
Hi! I got the same problem;
I new a project with dva-cli,and then add <script> tags in index.html;
when using window.less.modifyVars(),nothing hanppens;
hmm...my codebox https://codesandbox.io/s/yqolo5x76z
thanks
hmm...codescanbox doesn't works...
https://github.com/kstar11/dva-antd-theme-generator
I created a github repo...
thanks
I'll look into this