-
-
Notifications
You must be signed in to change notification settings - Fork 315
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Facing css import issue in create react app in typescript #300
Comments
Which version are you using? |
I have added the path of the suneditor.min.css in CopyWebpackPlugin in Webpack And use in my typescript file as import 'suneditor/dist/css/suneditor.min.css'; It works in my dev env but fails in Prod after build as shown in figure above |
It seems that the web font is not loaded. |
ok how do I use font import in CopyWebpackPlugin |
Sorry, I don't know..😭 |
I set it like this in my webpack environment. {
test: /\.(eot|svg|ttf|woff|woff2)(\?v=[0-9]\.[0-9]\.[0-9])?$/,
use: [{
loader: "file-loader",
options: {
publicPath: '../',
name: 'fonts/[hash].[ext]',
limit: 5000,
mimetype: 'application/font-woff'
}
}]
} Even if the web font is loaded with this setting, it is recommended to use the latest version. |
Can u let me know what is the improvement in switching to newer version |
Please refer to the release history. |
I was experiencing similar issues, as I have
...in my code as well. Here's what I've learned: in development mode, webpack is just copying the contents of that file and putting it into a |
According to csslint.com: Edit: this may be due to csslint not supporting custom properties. |
I think both my CSS syntax highlighter, Terser and CSS Lint don't understand the @keyframes spinner{
to {
transform: rotate(1turn);
}
} When I change it to: @keyframes spinner{
to {
transform: rotate(360deg);
}
} CSS Lint is happy. |
@rwaldron Thank for your feedback! cssnano/cssnano#823 |
The 2.30.0 version has been updated. |
I am facing css import issue in create react app in typescript
Can u please let me know how I can resolve this issue as I have imported the css into my typescript file as below
import 'suneditor/dist/css/suneditor.min.css';
The text was updated successfully, but these errors were encountered: