Bootstrap version
-
I ran in to an issue and my problem turned out to be caused by the version of Bootstrap that Virtue uses. I think Virtue uses Bootstrap 3.0.0 but the current version of Bootstrap is 3.3.1.
What are your plans to use a later version of Bootstrap?
Is it possible for a child theme to “override” and provide a later version of Bootstrap?
-
Can you tell me what the issue is?
Virtue uses only part of bootstrap 3 and it’s been edited. I’m looking into bootstrap 4 in the future.
And yes you can override the theme css with whatever css you want in a child theme.
Kadence Themes
The issue was that an element of mine that has the class
visible-xs-inline
was visible even when viewport was > 768px. After some investigating, I found the reason was that the version of Bootstrap that comes baked in with Virtue is 3.0.0, and thevisible-*-*
classes was introduced in Bootstrap 3.2.0.I can work around that particular issue, but I am curious about being able to use the latest Bootstrap version, though.
If you build and rely on a customized version of Bootstrap, I am not sure it would be so wise for me to override it with a non-customized version – things that you/Virtue expect may then no longer hold true.
I am not a WordPress expert – it appears that Bootstrap is not enqueued separately but rather baked in with the Virtue css (and others), right? So when you say I can override the theme css I would then have to provide a full replacement of assets/css/virtue.css, right? Or, alternatively, load another version of Bootstrap in addition to, and after, virtue.css, right?
Either way seems to be messy and probably not worth it. But I am interested to learn and see if I am thinking about it the right way.
And regardless, it would be great to be able to use the latest version of Bootstrap… ??Honestly I don’t know what would be “great to use in the latest” but there are plugins you can add to bootstrap css into your site.
If your going to override the theme you have to dequeue the theme css and copy what you want of it into a child theme.
Really if you want just the new visible css to function I would just add that separately.
Kadence Themes
I stated – “it would be great to be able to use the latest version of Bootstrap”. I don’t know if you are serious if you say you honestly don’t know why it would be a good thing to use the latest version of Bootstrap as opposed to using an old version of Bootstrap.
Nevertheless, here are the reasons:
https://github.com/twbs/bootstrap/releases/tag/v3.0.1
https://github.com/twbs/bootstrap/releases/tag/v3.0.2
https://github.com/twbs/bootstrap/releases/tag/v3.0.3
https://github.com/twbs/bootstrap/releases/tag/v3.1.0
https://github.com/twbs/bootstrap/releases/tag/v3.1.1
https://github.com/twbs/bootstrap/releases/tag/v3.2.0
https://github.com/twbs/bootstrap/releases/tag/v3.3.0
https://github.com/twbs/bootstrap/releases/tag/v3.3.1I simply meant in terms of what the theme uses of bootstrap. As I said it’s only using a small part and its an edited part. But your welcome to do what you like. (like adding a plugin with the latest bootstrap) If there is a specific feature or function that you would like to requests as a feature request I would be happy to consider. This theme was never built to use all of the bootstrap styling (hence all the styling that isn’t bootstrap in the theme) and only uses part of the grid framework (an edited version). Bootstrap 3 for example has no method for controlling what a page looks like when a phone is portrait or landscape. Virtue adds support for that. It also fixes all the print styles so your page does’t fall apart when you print. along with other things. You can see what of the bootstrap framework is there in the assets/css/bootstrap folder.
Please don’t hesitate to report a bug or post a feature request.
Kadence Themes
Thanks for elaborating.
I am perhaps coming from a slightly different angle to this theme than most others. The site I am working on has several non-blog pages and one of the primary reasons I chose Virtue as theme is that it is Bootstrap-based. I want to be able to use Bootstrap and its functionality in the content area, preferably any and all Bootstrap functionality and the latest version of Bootstrap. You as a theme author and theme provider may not need all of Bootstrap and may not need the later/latest version, but for me as a user of Virtue it is great to have all of Bootstrap (and latest version) in my toolbox for the html I author for the content area of “custom” pages.Regarding loading up the latest version of Bootstrap, as I mentioned before, it seems like I could get into a mess real quick, especially since Virtue has made some customizations and expects certain styling of the Bootstrap classes. If I override/replace your version of Bootstrap with my (or the latest) version of Bootstrap then those expectations that Virtue has are broken.
You say that Virtue is not built to use all of Bootstrap. Are you saying that all of Bootstrap 3.0.0 is not included in virtue.css?
If so, I think, as a feature, it would be great if Virtue had an option to use the full version of Bootstrap. Virtue, the theme, may not need all the styling available in Bootstrap, but the user of Virtue may want to be able to use it in the html authored to be placed in a Virtue-themed site – maybe some parts of Bootstrap is customized to Virtue’s liking but at least nothing would be stripped out. I don’t know how difficult for you it would be to build one “stripped” version (like you do now) and one “complete” version where no Bootstrap functionality is stripped out. If it is not too complicated to do so, then a “Use Full Version Of Bootstrap” option in Theme Options could be used to control which of the two versions of virtue.css would be used.Hey,
I’m not explaining well. You can use the latest bootstrap without breaking anything. Add this pluign: WordPress Twitter Bootstrap CSSIt will not override the theme added features.
Kadence Themes
- The topic ‘Bootstrap version’ is closed to new replies.