[Solved] If I built an app with a CSS framework, and then they change their styles, would the look of my site change with? [closed]


Question 1

As mentioned in the question, say one of these front end libraries were to update their UI components, would these changes reflect in my app or is it version dependent?

Oh, yes, the appearance of your site will definitely change.

Suppose you had this CSS library:

.ui {
  font-family:system-ui;
}
body {
  background-image:url("/some/image/and/the/file.jpg");
  background-attachment:fixed;
}

Once you apply this style to your site, your HTML document body would have a background image of /some/image/and/the/file.jpg.

But suppose the creators of the library changed it to…

@0:0, 20:0;
... <continued>
body {
  background-image:url("/some/image/and/the/other/file.jpg");
  background-attachment:fixed;
}

This would change your site’s background image.

If you can’t try it out on your own, run the two snippets below.

  • Snippet #1:
body {
  font-family:Monaco, Consolas, monospace;
  background-color:blue;
  color:white;
  overflow:hidden;
}
<code>A problem has been detected. This is fake, so Stack Snippets can continue.</code>
<br><br>
<code>Blah blah blah. Please blah blah blah and then blah blah blah.</code>

It has a background color of blue, with a color of white, and a font-family of Monaco, Consolas, monospace.

  • Snippet #2 (notice the change):
body {
  font-family:Consolas, "Courier New", monospace;
  background-color:cyan;
  color:black;
  overflow:hidden;
}
<code>A problem has been detected. This is fake, so Stack Snippets can continue.</code>
<br><br>
<code>Blah blah blah. Please blah blah blah and then blah blah blah.</code>

Here, the (hypothetical) library authors changed the font-family to Consolas, “Courier New”, monospace, set the background color to cyan, and made the text black.

Because the library changed (and remember: libraries are just also normal CSS rulesets), the elements they modify also change.

It’s just CSS. Nothing fancy. Changing CSS also does change the Web page it styles, doesn’t it?

Question 2

If for whatever reason one of these libraries were to cease to exist or cease to contribute, after having built an entire app around them, what would happen?

  • If they ceased to contribute (i.e. continued as they were and did not change), your app would look the same. This is because the CSS styling (recall, again, CSS frameworks are just a huge collection of rulesets) it is the same.
  • If they ceased to work, then your site would be back to the styles you set. Let’s try removing the CSS from the snippet above:
/* All the styles have been removed! */
<code>A problem has been detected. This is fake, so Stack Snippets can continue.</code>
<br><br>
<code>Blah blah blah. Please blah blah blah and then blah blah blah.</code>

That HTML is the same, only the CSS has been removed. This causes the browser to fall back to default styles. If you have your own styles, those would still be applied.

But when would it not be applied?

  • When you have your own styles using !important. This overrides the library.
  • When the library affected none of your elements.

2

solved If I built an app with a CSS framework, and then they change their styles, would the look of my site change with? [closed]