Skip to content

Cannot apply class to body tag #597

@stevebeauge

Description

@stevebeauge

Hello,

I've created a simple app using create-react-app for learning purpose. I'd like to integrate an external CSS framework that requires applying a class to the body tag. The framework is Office UI Fabric.

<body class="ms-font-m">

I included these framework from my index.js file using import 'office-ui-fabric/dist/css/fabric.css';

However, at run time, the body is not styled.

I guess this is due to bundling of the css file, not included as a css file directly, but it's a bit obscure.

As a workaround, I was able to clone the CSS rule from the framework to a local body rule in my app.css file.

In a more general way, can I apply class to body tag?

thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions