Giter Club home page Giter Club logo

Comments (7)

moritzgloeckl avatar moritzgloeckl commented on May 27, 2024 1

Ah ok I see! I thought maybe there's a better way to do it. Thank you very much for your help, and thank you for your work on this.

from ng-bootstrap-to-bootstrap-3.

trumbitta avatar trumbitta commented on May 27, 2024

Hi @moritzgloeckl,

since your bootstrap.css is a link in index.html, if you make sure that ng-bootstrap-to-bootstrap-3.min.css ends up after bootstrap.css in the cascade, it should be fine.

from ng-bootstrap-to-bootstrap-3.

moritzgloeckl avatar moritzgloeckl commented on May 27, 2024

Hi @trumbitta ,

thanks for the fast reply, when I'm using

<link rel="stylesheet" type="text/css" href="~ng-bootstrap-to-bootstrap-3/dist/ng-bootstrap-to-bootstrap-3.min.css">`

it's not working. I thought maybe there's a better way than importing it in the style.css? How are you importing it?

from ng-bootstrap-to-bootstrap-3.

trumbitta avatar trumbitta commented on May 27, 2024

Can you post your non-working styles.css and your index.html so I can take a look at it?

from ng-bootstrap-to-bootstrap-3.

moritzgloeckl avatar moritzgloeckl commented on May 27, 2024

This is working:

--- index.html
<head>
  <link rel="stylesheet" type="text/css" href="https://bootswatch.com/flatly/bootstrap.min.css">
</head>
--- styles.css
@import '~ng-bootstrap-to-bootstrap-3/dist/ng-bootstrap-to-bootstrap-3.min.css'; 
body {
 ....

This isn't working:

--- index.html
<head>
  <link rel="stylesheet" type="text/css" href="https://bootswatch.com/flatly/bootstrap.min.css">
  <link rel="stylesheet" type="text/css" href="~ng-bootstrap-to-bootstrap-3/dist/ng-bootstrap-to-bootstrap-3.min.css">
</head>
--- styles.css
body {
 ....

from ng-bootstrap-to-bootstrap-3.

trumbitta avatar trumbitta commented on May 27, 2024

Oh, ok nice.

The first version, if it's working as intended, should be the preferred one. You installed ng-bootstrap-to-bootstrap-3 via NPM, so it makes sense to import it like that in styles.css - a file that ng cli and Webpack take care of.

from ng-bootstrap-to-bootstrap-3.

trumbitta avatar trumbitta commented on May 27, 2024

You could also directly use the .scss file(s), and let Webpack compile everything at build time. You'd have to use bootstrap-sass instead of a pre-compiled Bootstrap for that.

But I think your current setup is already ok as it is :)

from ng-bootstrap-to-bootstrap-3.

Related Issues (2)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.