erikras / erikras/react-redux-universal-hot-example

importation of style files from modules that I depend on.

Open
#911 5 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
12.1k
Forks
2.5k
PR merge metrics
No merged PRs in 30d

Description

I am trying to use react-toolbox which provides widgets and comes with its own style sheets.
http://react-toolbox.com/
but whenever I try to import any element, I get this error:

`
[0] ==> 🚧 Webpack development server listening on port 3001
[1] [webpack-isomorphic-tools] [error] asset not found: ./~/react-toolbox/lib/animations/slide-left.scss
[1] [webpack-isomorphic-tools] [error] asset not found: ./~/react-toolbox/lib/animations/slide-right.scss
[1] [webpack-isomorphic-tools] [error] asset not found: ./~/react-toolbox/lib/animations/zoom-in.scss
[1] [webpack-isomorphic-tools] [error] asset not found: ./~/react-toolbox/lib/animations/zoom-out.scss
[1] [webpack-isomorphic-tools] [error] asset not found: ./~/react-toolbox/lib/ripple/style.scss
[1] [webpack-isomorphic-tools] [error] asset not found: ./~/react-toolbox/lib/button/style.scss
[1] [webpack-isomorphic-tools] [error] asset not found: ./~/react-toolbox/lib/date_picker/style.calendar.scss
[1] [webpack-isomorphic-tools] [error] asset not found: ./~/react-toolbox/lib/overlay/style.scss
[1] [webpack-isomorphic-tools] [error] asset not found: ./~/react-toolbox/lib/dialog/style.scss
`

This happens with other libraries also. I am also tried to use react-bootstrap-datetimepickered
According to here, https://github.com/quri/react-bootstrap-datetimepicker/issues/141
I suppose to include the css file this way:

`
import 'react-bootstrap-datetimepicker/css/bootstrap-datetimepicker.min.css';
`
but I keep getting this error:
`[require-hook] Trying to load "bootstrap-datetimepicker.min.css" as a "*.js"`

I even changed webpack for dev.config.js to include .css files:

`
{
test: /.css$/, // Only .css files
loader: 'style!css' // Run both loaders
},

`

Does anyone have trouble loading CSS or SCSS style files that are used in different libraries installed via NPM?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.