Bootstrap trying to load map file. How to disable it? Do I need to do it?

前端 未结 13 990
情书的邮戳
情书的邮戳 2020-12-04 09:59

I\'m recently playing with bootsrap3. I compiled it from sources and included distr js and css to my project. The thing is, I see in GH dev tools, that it\'s trying to get .

相关标签:
13条回答
  • 2020-12-04 10:22

    From bootstrap.css remove remove last line /*# sourceMappingURL=bootstrap-theme.css.map */

    0 讨论(0)
  • 2020-12-04 10:23

    Deleting this line fixes it, but the problem is the boostrap files are in bower_components and not checked into source control.

    So, every developer on the team will get the css file with the map reference when they pull the repo and do bower install (which is part of using a new repo).

    The file should not have the reference to a map that is not there.

    0 讨论(0)
  • 2020-12-04 10:24

    Remove the line /*# sourceMappingURL=bootstrap.css.map */ in bootstrap.css

    If the error persists, clean the cache of the browser (CTRL + F5).

    0 讨论(0)
  • 2020-12-04 10:24

    Delete the line "/*# sourceMappingURL=bootstrap.min.css.map */ " in following files.

    • css/bootstrap.min.css
    • css/bootstrap.css

    To fetch the file path in Linux use the command find / -name "\*bootstrap\*"

    0 讨论(0)
  • 2020-12-04 10:26

    Okay Recently I faced this problem I have very simple solution for solve this Issue , follow these steps: go to these directories src-> app-> index.html open the index.html and find <base href="your app name ">change this to <base href="/">

    0 讨论(0)
  • 2020-12-04 10:27

    For me, created an empty bootstrap.css.map together with bootstrap.css and the error stopped.

    0 讨论(0)
提交回复
热议问题