Developer : Theme Creation


Hello! Just a few front-end developer questions!

  1. I am trying to customize a theme, based on a small React app I built using Styled-Components. Is there a way to map global style components to the Layout index.js file? I’m trying to find the best solution without having to re-write all my styling SCSS.

  2. Is there a way to lock the theme so the user can’t change any of the styled? Would that just be roles assigned to the user?



Hi @caitlinmsweeney,

  1. I wouldn’t say this is possible, at least not in any easy way. The hard way would be to rewrite the current plugins, like buttons, image components, and others, by providing a new custom “render” component, which then contains your Styled-Components. I would say this is a lot of work, and not worth the hassle. The preferred way would be to update the existing scss files that come with the default theme, it’s less work, and easier to maintain for the future.

  2. A user that has access only to the web interface cannot change the theme. The theme is defined in the code and the whole app needs to be re-built and re-deployed. So a user won’t have the option to change the theme at all, unless they have access to the source code.

Hope this helps.