SharePoint 2016 on premise - Can I have a global CSS file at the site collection or site level then just apply the .CSS (SASS) classes at the web part level?

SharePoint 2016 on premise - Can I have a global CSS file at the site collection or site level then just apply the .CSS (SASS) classes at the web part level?

I am reading that SharePoint 2016 is now supporting SASS, and it looks like in all the examples each web part has its own CSS file. Is this a requirement or can I have a single global and just assign the .class to the web part?

Also is there a reason having a global .css at the site or site collection level is a bad idea?
LVL 1
sqlagent007Asked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

sqlagent007Author Commented:
Can the CSS be applied to a specific field?
0
kukdaiCommented:
You can still overwrite or write a class and as long as it is getting called then you will be able to use in across the Site.

Let's say
ms-webpart-chrome-title

 this class is for web part title which is used by every web part all over the site collection. you can modify this class and add important at the end to make sure it is getting executed
\
.ms-webpart-chrome-title{
Font-Size:28px !important;
}
which will make all the web part titles 28px large no matter what.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
sqlagent007Author Commented:
Thanks!
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft SharePoint

From novice to tech pro — start learning today.