Search code examples
javascriptdombuildfire

Override or remove the appTheme CSS injected into a Buildfire App


So I faced the challenge of created a large custom app through the Buildfire platform. The client had a lot of custom element styles that were being overridden by the appTheme settings in the dashboard, and overriding these styles in traditional CSS fashion was growing to be a monumental task.

I wrote this small function to remove the custom styles injected into the application and so far all of the client's custom styling is showing correctly.

I figured I would share this with the community since this has been an issue without resolution for our team.


Solution

  • If you wish to disable the appTheme CSS in your plugin, you can simply use a meta tag in the widget's HTML, like so:

    <meta name="buildfire" content="disableTheme">
    

    This is covered the SDK wiki under the meta tag section.