As my understanding from the README, I just need to install the less as the dependency and set modules: true then I can import less file as css modules like this:
// MyComponent.tsx
import styles from "./MyComponent.less"
But I get the errror: [!] (rpt2 plugin) Error: ... semantic error TS2307 Cannot find module './MyComponent.less' after running the rollup -c.
I use the rollup-plugin-css version 1.6.2 and rollup version 0.62.0
As my understanding from the README, I just need to install the
less
as the dependency and setmodules: true
then I can import less file as css modules like this:But I get the errror:
[!] (rpt2 plugin) Error: ... semantic error TS2307 Cannot find module './MyComponent.less'
after running therollup -c
.I use the rollup-plugin-css version 1.6.2 and rollup version 0.62.0
My rollup.config.js: