N
N
Nikolai2018-07-06 19:05:22
css
Nikolai, 2018-07-06 19:05:22

How to properly include css in sass?

Good afternoon! How to correctly include css in sass

@import "../libs/bootstrap/scss/bootstrap-reboot.scss"
@import "../libs/bootstrap/scss/bootstrap-grid.scss"
@import "../libs/bootstrap/scss/utilities/_sizing.scss"
@import "../libs/jQuery.mmenu-master/jquery.mmenu.all" - это css
@import "../libs/fontawesome/css/fa-svg-with-js" - это css

gives
DEPRECATION WARNING on line 4, column 8 of C:/Users/Nikolay/Desktop/fasovkin/dev/base/_libs.sass:
Including .css files with @import is non-standard behavior which will be removed in future versions in console of LibSass.
Use a custom importer to maintain this behavior. Check your implementations documentation on how to create a custom importer.

Answer the question

In order to leave comments, you need to log in

4 answer(s)
E
Elwen, 2018-07-06
@Elwen

Convert css to scss and import it. Since any valid css is valid scss, it is enough to change the file extension. In turn, scss and sass are quite compatible.
If you don't care about the order in which styles are included in css, then you can also add a step to your gulpfile to convert css to scss and merge scss and sass through gulp.

V
Viktor Yanyshev, 2018-07-06
@villiwalla

Yandex quite tolerably translates.
Including .css files with @import is non-standard behavior which will be removed in future versions of LibSass.
≠===========
Inclusive. css files with @import are non-standard behavior that will be removed in future versions of LibSass. And now check styles are imported or not.

P
PhSh, 2014-11-05
@PhSh

I didn’t understand about the orange frame) jsfiddle.net/h53pa6tg/2

A
Alexander Tsymbal, 2014-11-05
@AlexanderTsymbal

experiment with margin: 0 0 0 0; padding: 0 0 0 0 four values ​​will help set the indents top-right-bottom-left (like on the clock, 12, 3, 6, 9 o'clock).
and to make the border not completely, you need to try changing display: block to display: inline-block (all divs have display equal to block by default, because div is a block element)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question