Closed sjf125 closed 8 years ago
@J-Weeks What's the best way to remove
<link href='https://fonts.googleapis.com/css?family=Quicksand' rel='stylesheet' type='text/css'>
from the header and store it (and dependencies) in vendor.bundle.js
?
I would use the SASS syntax to import it
So something like @import url(https://fonts.googleapis.com/css?family=Open+Sans);
or even just add a font directory and add the js for the fonts in separate files. If Sean really wanted to be cool he could find a font loader and do some light webpack configuration.
Thanks! I've removed
<link href='https://fonts.googleapis.com/css?family=Quicksand' rel='stylesheet' type='text/css'>
and have replaced it with the scss @import, but my cell styling is still getting overridden by bootstrap. :/
Here's my current import list - maybe the order has something to do with it?
$icon-font-path: '~bootstrap-sass/assets/fonts/bootstrap/';
@import '~bootstrap-sass/assets/stylesheets/bootstrap';
@import url(https://fonts.googleapis.com/css?family=Quicksand);
@import 'breakpoints';
@import 'colors';
@import 'typography';
@import 'board';
@import 'cells';
@import 'scoreboard';
The order in which you import things in the index.scss file can mess things up sometimes
I tried moving @import '~bootstrap-sass/assets/stylesheets/bootstrap';
to the end, but still overrode my styling.
@J-Weeks Wouldn't that put the imported files in bundle.js
not vendor.bundle.js
?
@sjf125 If it's being overridden then the bootstrap styling is probably more specific than your styling.
@gaand In my experience it has worked both locally and when built. I see @laurenfazah self-assigned. Already so I'm curious what the solution will be.
Got it, thanks Lauren! 'mark' is a reserved class in bootstrap as it turns out - changing the class name fixed it.
I have rounded squares with a light green color that has a hover effect, but when I enable bootstrap, they all become light yellow un-rounded squares with no hover effect. For the time being I have disabled bootstrap styling by commenting out the @import so I have the styling I want. I have gone over my scss files and my html to see if removing classes or moving things around would help, to no avail. Below is the code I have:
index.scss:
cells.scss:
colors.scss:
index.html: